开发者

CKEditor : How to load the my own javascript file

I am using CKEditor in my web app and new to it. It seems my js file isn't downloading with CKEditor, ho开发者_Python百科w to include external js files in CKEditor ?


Configuration related js needs to be in config.js

All plugin related files go in the plugins plugins/[plugin_name]/plugin.js You'll need to add them to the config using extraPlugins config.extraPlugins: 'plugin',

If you want to do something else you can just load another .js

for example:

<script type="text/javascript" src="ckeditor/ckeditor.js"></script>
<script type="text/javascript" src="customcode.js"></script></code>

in customcode.js you can put your eventhandling and overrides

CKEDITOR.on( 'instanceReady', function( ev )
{
    alert("CKEditor is loaded");
});
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜