kindeditor怎样获得焦点?
用afterFocus类,例如:
var editor;
KindEditor.ready(function(K) {
editor = K.create('#Neir', {
resizeType : 1,
allowPreviewEmoticons : false,
allowImageUpload : false,
afterFocus : function(){
self.edit = edit = this;if(self.edit.html()=="回复内容字数不少于10字。"){self.edit.html("") ;}
},
afterBlur : function(){
self.edit = edit = this;if(self.edit.html()==""){self.edit.html("回复内容字数不少于10字。") ;}
},
items : [
'fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline','removeformat', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
'insertunorderedlist', '|', 'emoticons', 'image', 'link']
});
});
kindeditor 文本编辑器怎么获得焦点
用afterFocus类,例如:
var editor;
KindEditor.ready(function(K) {
editor = K.create('#Neir', {
resizeType : 1,
allowPreviewEmoticons : false,
allowImageUpload : false,
afterFocus : function(){
self.edit = edit = this;if(self.edit.html()=="回复内容字数不少于10字。"){self.edit.html("") ;}
},
afterBlur : function(){
self.edit = edit = this;if(self.edit.html()==""){self.edit.html("回复内容字数不少于10字。") ;}
},
items : [
'fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline','removeformat', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
'insertunorderedlist', '|', 'emoticons', 'image', 'link']
});
});