- id
ID of TEXTAREA. Must be specified.
Type:String - items
Tool bar items. "-" for a new line.
Type:Array
Default:['source', 'fullscreen', 'undo', 'redo', 'print', 'cut', 'copy', 'paste',
'plainpaste', 'wordpaste', 'justifyleft', 'justifycenter', 'justifyright',
'justifyfull', 'insertorderedlist', 'insertunorderedlist', 'indent', 'outdent', 'subscript',
'superscript', 'selectall', '-',
'title', 'fontname', 'fontsize', 'textcolor', 'bgcolor', 'bold',
'italic', 'underline', 'strikethrough', 'removeformat', 'image',
'flash', 'media', 'table', 'hr', 'emoticons', 'link', 'unlink', 'about']
- width
Editor width, ending with "px" or "%". Inline width style of TEXTAREA will be ignored if this attribute is set.
Type:String - height
Editor width, ending with "px". Inline height style of TEXTAREA will be ignored if this attribute is set
Type:String - minWidth
Editor minimun width in px.
Type:Int
Default:200 - minHeight
Editor minimun height in px.
Type:Int
Default:100 - filterMode
Only HTML tags/attributes name defined in htmlTags will be accepted when set to true, or false to accept all tags.
Type:Boolean
Default:false - htmlTags
HTML tags/attributes names to be accepted. Keys for HTML tag names, values HTML attributes. Ones starting with "." for style names.
Type:Object
Default:{
Note: This attribute works only when filterMode is set to true.
font : ['color', 'size', 'face', '.background-color'],
span : ['style'],
div : ['class', 'align', 'style'],
table: ['class', 'border', 'cellspacing', 'cellpadding', 'width', 'height', 'align', 'style'],
'td,th': ['class', 'align', 'valign', 'width', 'height', 'colspan', 'rowspan', 'bgcolor', 'style'],
a : ['class', 'href', 'target', 'name', 'style'],
embed : ['src', 'width', 'height', 'type', 'loop', 'autostart', 'quality',
'style', 'align', 'allowscriptaccess', '/'],
img : ['src', 'width', 'height', 'border', 'alt', 'title', 'align', 'style', '/'],
hr : ['class', '/'],
br : ['/'],
'p,ol,ul,li,blockquote,h1,h2,h3,h4,h5,h6' : ['align', 'style'],
'tbody,tr,strong,b,sub,sup,em,i,u,strike' : []
}
- resizeMode
Could be 2 or 1 or 0. 2 for that width and height are both resizable, 1 for height, 0 for none.
Type:Int
Default:2 - skinType
Theme name. Could be "default" or "office".
Type:String
Default:oxygen - wyswygMode
True for WYSIWYG view or false for code view.
Type:Boolean
Default:true - autoOnsubmitMode
If it's set to true, HTML generated by kind editor will be filled back into TEXTAREA when onsubmit of form is fired.
Type:Boolean
Default:true - cssPath
Css path for editor.
Type:String
Default:""(empty) - skinsPath
Theme path for css and images files.
Type:String
Default: KE.scriptPath + 'skins/' - pluginsPath
Path of plugins.
Type:String
Default:KE.scriptPath + 'plugins/' - minChangeSize
Only after more than minChangeSize charactors change, a snapshot will be taken and put into redo/undo stack.
Type: Int
Default:5 - loadStyleMode
To load css file automatically or not. True for yes, false for no.
Type:Boolean
Default: true - urlType
URL type. Could be relative/absolute/domain. Relative for relative path, absolute for absolute path, domain for absolute path with domain name.
Type:Boolean
Default:relative - newlineTag
Tag for new line when end user presses "Enter" key.
Type:Boolean
Default:br
Editor Attributes
The following atributes can be passed in when KE.showorKE.init is called.
KE.show({
id : "content_1",
width : "70%",
height : "200px",
filterMode : false, //no filter applied on raw HTML
resizeMode : 1 //height resizable only
});