<script>
var options = {
filterMode : true,
allowImageUpload : true,
items : [
'source', 'fullscreen', '|', 'fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline',
'removeformat', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
'insertunorderedlist', '|', 'emoticons', 'image', 'link'
],
width : '600px',
height: '250px',
emoticonsPath : './static/emoticons/',
uploadJson :
"{pigcms{$config.site_url}/index.phpg=Index&c=Upload&a=editor_ajax_upload&upload_dir=system/news"
};
var editor = new Array(); //添加多个编辑器
KindEditor.ready(function(K) {
editor[0] = K.create("#content",options);
editor[1] = K.create("#introduction",options);
});
</script>
如果想使用更多的kindeditor编辑器,只需要在那个数组里多添加一个元素就可以了。。
文章来源于:https://blog.csdn.net/ougexingfuba/article/details/72917194