代码如下
var editor, html = 'Hello,world!';
function createEditor() {
if ( editor )
return;
// Create a new editor ins ide the <div id="editor">, setting its value to html
var config = {
width : 610,
height : 300,
resize_enabled : false,
toolbar : [
['Cut','Copy','Paste','PasteText','PasteFromWord'],
['Undo','Redo','-','Find','Replace','-','SelectAll','RemoveFormat'],
['Form','Checkbox','Radio','TextField','Textarea','Select','Button','ImageButton','HiddenField'],
'/',
['Bold','Italic','Underline','Strike','-','Subscript','Superscript'],
['NumberedList','BulletedList','-','Outdent','Indent','Blockquote'],
['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
['Link','Unlink','Anchor'],
['Image','Flash','Table','HorizontalRule','Smiley','SpecialChar','PageBreak'],
'/',
['Styles','Format','Font','FontSize'],
['TextColor','BGColor'],
['Maxmize','ShowBlocks']
]};
editor = CKEDITOR.appendTo( 'editor', config, html );
ie里的编辑器没有全屏的按钮: