ExtJs Ext.form.field.TextArea+Ckeditor 扩展富文本编辑器
时间:2014-02-21 00:28:00
收藏:0
阅读:816
Ext.define("MyApp.base.BaseTextArea", {
extend: "Ext.form.field.TextArea",
xtype: "BaseTextArea",
editor: null,
initComponent: function() {
this.callParent();
this.on("afterrender", this.handlerAfterrender);
},
handlerAfterrender: function(txa, eOpts) {
var editor = CKEDITOR.replace(txa.getInputId());
CKFinder.setupCKEditor(editor,‘/ckeditor/‘);
txa.editor = editor;
},
getSubmitValue: function() {
this.editor.updateElement();
return this.callParent();
}
});
原文:http://www.cnblogs.com/daxin/p/3557427.html
评论(0)
