{"id":1229,"date":"2010-07-29T13:33:00","date_gmt":"2010-07-29T05:33:00","guid":{"rendered":""},"modified":"2010-07-29T13:33:00","modified_gmt":"2010-07-29T05:33:00","slug":"","status":"publish","type":"post","link":"https:\/\/kyle.ai\/blog\/1229.html","title":{"rendered":"CKEditor\u7684\u8be6\u7ec6\u914d\u7f6e"},"content":{"rendered":"<p><html><head><meta http-equiv=\"Content-Type\" content=\"text\/html; charset=utf-8\" \/><title>CKEditor\u7684\u8be6\u7ec6\u914d\u7f6e<\/title><\/head><body><\/p>\n<h1 style=\"display:none\">CKEditor\u7684\u8be6\u7ec6\u914d\u7f6e<\/h1>\n<div>\n<p>\u4e00\u3001\u4f7f\u7528\u65b9\u6cd5\uff1a<\/p>\n<p>1\u3001\u5728\u9875\u9762&lt;head&gt;\u4e2d\u5f15\u5165ckeditor\u6838\u5fc3\u6587\u4ef6ckeditor.js<\/p>\n<p>&lt;script type=&quot;text\/javascript&quot; src=&quot;ckeditor\/ckeditor.js&quot;&gt;&lt;\/script&gt;<\/p>\n<p>2\u3001\u5728\u4f7f\u7528\u7f16\u8f91\u5668\u7684\u5730\u65b9\u63d2\u5165HTML\u63a7\u4ef6&lt;textarea&gt;<\/p>\n<p>&lt;textarea id=&quot;TextArea1&quot; cols=&quot;20&quot; rows=&quot;2&quot; class=&quot;ckeditor&quot;&gt;&lt;\/textarea&gt;<\/p>\n<p>\u5982\u679c\u662fASP.NET\u73af\u5883\uff0c\u4e5f\u53ef\u7528\u670d\u52a1\u5668\u7aef\u63a7\u4ef6&lt;TextBox&gt;<\/p>\n<p>&lt;asp:TextBox ID=&quot;tbContent&quot; runat=&quot;server&quot; TextMode=&quot;MultiLine&quot; class=&quot;ckeditor&quot;&gt;&lt;\/asp:TextBox&gt;<\/p>\n<p>\u6ce8\u610f\u5728\u63a7\u4ef6\u4e2d\u52a0\u4e0a class=&quot;ckeditor&quot; \u3002<\/p>\n<p>3\u3001\u5c06\u76f8\u5e94\u7684\u63a7\u4ef6\u66ff\u6362\u6210\u7f16\u8f91\u5668\u4ee3\u7801<\/p>\n<p>&lt;script type=&quot;text\/javascript&quot;&gt;<br \/>\nCKEDITOR.replace(&#8216;TextArea1&#8217;);<br \/>\n\/\/\u5982\u679c\u662f\u5728ASP.NET\u73af\u5883\u4e0b\u7528\u7684\u670d\u52a1\u5668\u7aef\u63a7\u4ef6&lt;TextBox&gt;<br \/>\nCKEDITOR.replace(&#8216;tbContent&#8217;);<br \/>\n\/\/\u5982\u679c&lt;TextBox&gt;\u63a7\u4ef6\u5728\u6bcd\u7248\u9875\u4e2d\uff0c\u8981\u8fd9\u6837\u5199<br \/>\nCKEDITOR.replace(&#8216;&lt;%=tbContent.ClientID.Replace(&quot;_&quot;,&quot;$&quot;) %&gt;&#8217;);<br \/>\n&lt;\/script&gt;<\/p>\n<p>4\u3001\u914d\u7f6e\u7f16\u8f91\u5668<\/p>\n<p>&nbsp;&nbsp;&nbsp;  ckeditor\u7684\u914d\u7f6e\u90fd\u96c6\u4e2d\u5728 ckeditor\/config.js \u6587\u4ef6\u4e2d\uff0c\u4e0b\u9762\u662f\u4e00\u4e9b\u5e38\u7528\u7684\u914d\u7f6e\u53c2\u6570\uff1a<\/p>\n<p>\/\/ \u754c\u9762\u8bed\u8a00\uff0c\u9ed8\u8ba4\u4e3a &#8216;en&#8217;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  config.language = &#8216;zh-cn&#8217;;<\/p>\n<p>\/\/ \u8bbe\u7f6e\u5bbd\u9ad8<\/p>\n<p>&nbsp;&nbsp;&nbsp;  config.width = 400;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  config.height = 400;<\/p>\n<p>\/\/ \u7f16\u8f91\u5668\u6837\u5f0f\uff0c\u6709\u4e09\u79cd\uff1a&#8217;kama&#8217;\uff08\u9ed8\u8ba4\uff09\u3001&#8217;office2003&#8217;\u3001&#8217;v2&#8242;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  config.skin = &#8216;v2&#8217;;<\/p>\n<p>\/\/ \u80cc\u666f\u989c\u8272<\/p>\n<p>&nbsp;&nbsp;&nbsp;  config.uiColor = &#8216;#FFF&#8217;;<\/p>\n<p>\/\/ \u5de5\u5177\u680f\uff08\u57fa\u7840&#8217;Basic&#8217;\u3001\u5168\u80fd&#8217;Full&#8217;\u3001\u81ea\u5b9a\u4e49\uff09plugins\/toolbar\/plugin.js<\/p>\n<p>&nbsp;&nbsp;&nbsp;  config.toolbar = &#8216;Basic&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  config.toolbar = &#8216;Full&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \u8fd9\u5c06\u914d\u5408\uff1a<br \/>\nconfig.toolbar_Full = [<br \/>\n[&#8216;Source&#8217;,&#8217;-&#8216;,&#8217;Save&#8217;,&#8217;NewPage&#8217;,&#8217;Preview&#8217;,&#8217;-&#8216;,&#8217;Templates&#8217;],<br \/>\n[&#8216;Cut&#8217;,&#8217;Copy&#8217;,&#8217;Paste&#8217;,&#8217;PasteText&#8217;,&#8217;PasteFromWord&#8217;,&#8217;-&#8216;,&#8217;Print&#8217;, &#8216;SpellChecker&#8217;, &#8216;Scayt&#8217;],<br \/>\n[&#8216;Undo&#8217;,&#8217;Redo&#8217;,&#8217;-&#8216;,&#8217;Find&#8217;,&#8217;Replace&#8217;,&#8217;-&#8216;,&#8217;SelectAll&#8217;,&#8217;RemoveFormat&#8217;],<br \/>\n[&#8216;Form&#8217;, &#8216;Checkbox&#8217;, &#8216;Radio&#8217;, &#8216;TextField&#8217;, &#8216;Textarea&#8217;, &#8216;Select&#8217;, &#8216;Button&#8217;, &#8216;ImageButton&#8217;, &#8216;HiddenField&#8217;],<br \/>\n&#8216;\/&#8217;,<br \/>\n[&#8216;Bold&#8217;,&#8217;Italic&#8217;,&#8217;Underline&#8217;,&#8217;Strike&#8217;,&#8217;-&#8216;,&#8217;Subscript&#8217;,&#8217;Superscript&#8217;],<br \/>\n[&#8216;NumberedList&#8217;,&#8217;BulletedList&#8217;,&#8217;-&#8216;,&#8217;Outdent&#8217;,&#8217;Indent&#8217;,&#8217;Blockquote&#8217;],<br \/>\n[&#8216;JustifyLeft&#8217;,&#8217;JustifyCenter&#8217;,&#8217;JustifyRight&#8217;,&#8217;JustifyBlock&#8217;],<br \/>\n[&#8216;Link&#8217;,&#8217;Unlink&#8217;,&#8217;Anchor&#8217;],<br \/>\n[&#8216;Image&#8217;,&#8217;Flash&#8217;,&#8217;Table&#8217;,&#8217;HorizontalRule&#8217;,&#8217;Smiley&#8217;,&#8217;SpecialChar&#8217;,&#8217;PageBreak&#8217;],<br \/>\n&#8216;\/&#8217;,<br \/>\n[&#8216;Styles&#8217;,&#8217;Format&#8217;,&#8217;Font&#8217;,&#8217;FontSize&#8217;],<br \/>\n[&#8216;TextColor&#8217;,&#8217;BGColor&#8217;]<br \/>\n];<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5de5\u5177\u680f\u662f\u5426\u53ef\u4ee5\u88ab\u6536\u7f29<br \/>\nconfig.toolbarCanCollapse = true;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5de5\u5177\u680f\u7684\u4f4d\u7f6e<br \/>\nconfig.toolbarLocation = &#8216;top&#8217;;\/\/\u53ef\u9009\uff1abottom<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5de5\u5177\u680f\u9ed8\u8ba4\u662f\u5426\u5c55\u5f00<br \/>\nconfig.toolbarStartupExpanded = true;<\/p>\n<p>\/\/ \u53d6\u6d88 &ldquo;\u62d6\u62fd\u4ee5\u6539\u53d8\u5c3a\u5bf8&rdquo;\u529f\u80fd plugins\/resize\/plugin.js<br \/>\nconfig.resize_enabled = false;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u6539\u53d8\u5927\u5c0f\u7684\u6700\u5927\u9ad8\u5ea6<\/p>\n<p>&nbsp;&nbsp;&nbsp;  config.resize_maxHeight = 3000;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u6539\u53d8\u5927\u5c0f\u7684\u6700\u5927\u5bbd\u5ea6<br \/>\nconfig.resize_maxWidth = 3000;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u6539\u53d8\u5927\u5c0f\u7684\u6700\u5c0f\u9ad8\u5ea6<br \/>\nconfig.resize_minHeight = 250;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u6539\u53d8\u5927\u5c0f\u7684\u6700\u5c0f\u5bbd\u5ea6<br \/>\nconfig.resize_minWidth = 750;<br \/>\n\/\/ \u5f53\u63d0\u4ea4\u5305\u542b\u6709\u6b64\u7f16\u8f91\u5668\u7684\u8868\u5355\u65f6\uff0c\u662f\u5426\u81ea\u52a8\u66f4\u65b0\u5143\u7d20\u5185\u7684\u6570\u636e<br \/>\nconfig.autoUpdateElement = true;<\/p>\n<p>\/\/ \u8bbe\u7f6e\u662f\u4f7f\u7528\u7edd\u5bf9\u76ee\u5f55\u8fd8\u662f\u76f8\u5bf9\u76ee\u5f55\uff0c\u4e3a\u7a7a\u4e3a\u76f8\u5bf9\u76ee\u5f55<br \/>\nconfig.baseHref = &#8221;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/ \u7f16\u8f91\u5668\u7684z-index\u503c<br \/>\nconfig.baseFloatZIndex = 10000;<\/p>\n<p>\/\/\u8bbe\u7f6e\u5feb\u6377\u952e<br \/>\nconfig.keystrokes = [<br \/>\n[ CKEDITOR.ALT + 121 \/*F10*\/, &#8216;toolbarFocus&#8217; ], \/\/\u83b7\u53d6\u7126\u70b9<br \/>\n[ CKEDITOR.ALT + 122 \/*F11*\/, &#8216;elementsPathFocus&#8217; ], \/\/\u5143\u7d20\u7126\u70b9<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  [ CKEDITOR.SHIFT + 121 \/*F10*\/, &#8216;contextMenu&#8217; ], \/\/\u6587\u672c\u83dc\u5355<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  [ CKEDITOR.CTRL + 90 \/*Z*\/, &#8216;undo&#8217; ], \/\/\u64a4\u9500<br \/>\n[ CKEDITOR.CTRL + 89 \/*Y*\/, &#8216;redo&#8217; ], \/\/\u91cd\u505a<br \/>\n[ CKEDITOR.CTRL + CKEDITOR.SHIFT + 90 \/*Z*\/, &#8216;redo&#8217; ], \/\/<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  [ CKEDITOR.CTRL + 76 \/*L*\/, &#8216;link&#8217; ], \/\/\u94fe\u63a5<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  [ CKEDITOR.CTRL + 66 \/*B*\/, &#8216;bold&#8217; ], \/\/\u7c97\u4f53<br \/>\n[ CKEDITOR.CTRL + 73 \/*I*\/, &#8216;italic&#8217; ], \/\/\u659c\u4f53<br \/>\n[ CKEDITOR.CTRL + 85 \/*U*\/, &#8216;underline&#8217; ], \/\/\u4e0b\u5212\u7ebf<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  [ CKEDITOR.ALT + 109 \/*-*\/, &#8216;toolbarCollapse&#8217; ]<br \/>\n]<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8bbe\u7f6e\u5feb\u6377\u952e \u53ef\u80fd\u4e0e\u6d4f\u89c8\u5668\u5feb\u6377\u952e\u51b2\u7a81 plugins\/keystrokes\/plugin.js.<br \/>\nconfig.blockedKeystrokes = [<br \/>\nCKEDITOR.CTRL + 66 \/*B*\/,<br \/>\nCKEDITOR.CTRL + 73 \/*I*\/,<br \/>\nCKEDITOR.CTRL + 85 \/*U*\/<br \/>\n]<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8bbe\u7f6e\u7f16\u8f91\u5185\u5143\u7d20\u7684\u80cc\u666f\u8272\u7684\u53d6\u503c plugins\/colorbutton\/plugin.js.<br \/>\nconfig.colorButton_backStyle = {<br \/>\nelement : &#8216;span&#8217;,<br \/>\nstyles : { &#8216;background-color&#8217; : &#8216;#(color)&#8217; }<br \/>\n}<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8bbe\u7f6e\u524d\u666f\u8272\u7684\u53d6\u503c plugins\/colorbutton\/plugin.js<br \/>\nconfig.colorButton_colors = &#8216;000,800000,8B4513,2F4F4F,008080,000080,4B0082,696969,B22222,A52A2A,DAA520,<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  006400,40E0D0,0000CD,800080,808080,F00,FF8C00,FFD700,008000,0FF,00F,EE82EE,<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  A9A9A9,FFA07A,FFA500,FFFF00,00FF00,AFEEEE,ADD8E6,DDA0DD,D3D3D3,FFF0F5,<\/p>\n<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  FAEBD7,FFFFE0,F0FFF0,F0FFFF,F0F8FF,E6E6FA,FFF&rsquo;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u5728\u9009\u62e9\u989c\u8272\u65f6\u663e\u793a&ldquo;\u5176\u5b83\u989c\u8272&rdquo;\u9009\u9879 plugins\/colorbutton\/plugin.js<br \/>\nconfig.colorButton_enableMore = false<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u533a\u5757\u7684\u524d\u666f\u8272\u9ed8\u8ba4\u503c\u8bbe\u7f6e plugins\/colorbutton\/plugin.js<br \/>\nconfig.colorButton_foreStyle = {<br \/>\nelement : &#8216;span&#8217;,<br \/>\nstyles : { &#8216;color&#8217; : &#8216;#(color)&#8217; }<br \/>\n};<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u6240\u9700\u8981\u6dfb\u52a0\u7684CSS\u6587\u4ef6 \u5728\u6b64\u6dfb\u52a0 \u53ef\u4f7f\u7528\u76f8\u5bf9\u8def\u5f84\u548c\u7f51\u7ad9\u7684\u7edd\u5bf9\u8def\u5f84<br \/>\nconfig.contentsCss = &#8216;.\/contents.css&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u6587\u5b57\u65b9\u5411<br \/>\nconfig.contentsLangDirection = &#8216;rtl&#8217;; \/\/\u4ece\u5de6\u5230\u53f3<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/CKeditor\u7684\u914d\u7f6e\u6587\u4ef6 \u82e5\u4e0d\u60f3\u914d\u7f6e \u7559\u7a7a\u5373\u53ef<br \/>\nCKEDITOR.replace( &#8216;myfiled&#8217;, { customConfig : &#8216;.\/config.js&#8217; } );<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u754c\u9762\u7f16\u8f91\u6846\u7684\u80cc\u666f\u8272 plugins\/dialog\/plugin.js<br \/>\nconfig.dialog_backgroundCoverColor = &#8216;rgb(255, 254, 253)&#8217;; \/\/\u53ef\u8bbe\u7f6e\u53c2\u8003<br \/>\nconfig.dialog_backgroundCoverColor = &#8216;white&#8217; \/\/\u9ed8\u8ba4<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u80cc\u666f\u7684\u4e0d\u900f\u660e\u5ea6 \u6570\u503c\u5e94\u8be5\u5728\uff1a0.0\uff5e1.0 \u4e4b\u95f4 plugins\/dialog\/plugin.js<br \/>\nconfig.dialog_backgroundCoverOpacity = 0.5<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u79fb\u52a8\u6216\u8005\u6539\u53d8\u5143\u7d20\u65f6 \u8fb9\u6846\u7684\u5438\u9644\u8ddd\u79bb \u5355\u4f4d\uff1a\u50cf\u7d20 plugins\/dialog\/plugin.js<br \/>\nconfig.dialog_magnetDistance = 20;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u62d2\u7edd\u672c\u5730\u62fc\u5199\u68c0\u67e5\u548c\u63d0\u793a \u9ed8\u8ba4\u4e3a\u62d2\u7edd \u76ee\u524d\u4ec5firefox\u548csafari\u652f\u6301 plugins\/wysiwygarea\/plugin.js.<br \/>\nconfig.disableNativeSpellChecker = true<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8fdb\u884c\u8868\u683c\u7f16\u8f91\u529f\u80fd \u5982\uff1a\u6dfb\u52a0\u884c\u6216\u5217 \u76ee\u524d\u4ec5firefox\u652f\u6301 plugins\/wysiwygarea\/plugin.js<br \/>\nconfig.disableNativeTableHandles = true; \/\/\u9ed8\u8ba4\u4e3a\u4e0d\u5f00\u542f<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u5f00\u542f \u56fe\u7247\u548c\u8868\u683c \u7684\u6539\u53d8\u5927\u5c0f\u7684\u529f\u80fd config.disableObjectResizing = true;<br \/>\nconfig.disableObjectResizing = false \/\/\u9ed8\u8ba4\u4e3a\u5f00\u542f<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8bbe\u7f6eHTML\u6587\u6863\u7c7b\u578b<br \/>\nconfig.docType = &#8216;&lt;!DOCTYPE html PUBLIC &quot;-\/\/W3C\/\/DTD XHTML 1.0 Transitional\/\/EN&quot; &quot;<a >http:\/\/www.w3.org\/TR\/xhtml1\/DTD\/xhtml1-transitional.dtd%22&#8242;<\/a> ;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u5bf9\u7f16\u8f91\u533a\u57df\u8fdb\u884c\u6e32\u67d3 plugins\/editingblock\/plugin.js<br \/>\nconfig.editingBlock = true;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u7f16\u8f91\u5668\u4e2d\u56de\u8f66\u4ea7\u751f\u7684\u6807\u7b7e<br \/>\nconfig.enterMode = CKEDITOR.ENTER_P; \/\/\u53ef\u9009\uff1aCKEDITOR.ENTER_BR\u6216CKEDITOR.ENTER_DIV<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u4f7f\u7528HTML\u5b9e\u4f53\u8fdb\u884c\u8f93\u51fa plugins\/entities\/plugin.js<br \/>\nconfig.entities = true;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5b9a\u4e49\u66f4\u591a\u7684\u5b9e\u4f53 plugins\/entities\/plugin.js<br \/>\nconfig.entities_additional = &#8216;#39&#8217;; \/\/\u5176\u4e2d#\u4ee3\u66ff\u4e86&amp;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u8f6c\u6362\u4e00\u4e9b\u96be\u4ee5\u663e\u793a\u7684\u5b57\u7b26\u4e3a\u76f8\u5e94\u7684HTML\u5b57\u7b26 plugins\/entities\/plugin.js<br \/>\nconfig.entities_greek = true;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u8f6c\u6362\u4e00\u4e9b\u62c9\u4e01\u5b57\u7b26\u4e3aHTML plugins\/entities\/plugin.js<br \/>\nconfig.entities_latin = true;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u8f6c\u6362\u4e00\u4e9b\u7279\u6b8a\u5b57\u7b26\u4e3aASCII\u5b57\u7b26 \u5982&quot;This is Chinese: \u6c49\u8bed.&quot;\u8f6c\u6362\u4e3a&quot;This is Chinese: &amp;#27721;&amp;#35821;.&quot; plugins\/entities\/plugin.js<br \/>\nconfig.entities_processNumerical = false;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u6dfb\u52a0\u65b0\u7ec4\u4ef6<br \/>\nconfig.extraPlugins = &#8216;myplugin&#8217;; \/\/\u975e\u9ed8\u8ba4 \u4ec5\u793a\u4f8b<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u4f7f\u7528\u641c\u7d22\u65f6\u7684\u9ad8\u4eae\u8272 plugins\/find\/plugin.js<br \/>\nconfig.find_highlight = {<br \/>\nelement : &#8216;span&#8217;,<br \/>\nstyles : { &#8216;background-color&#8217; : &#8216;#ff0&#8217;, &#8216;color&#8217; : &#8216;#00f&#8217; }<br \/>\n};<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u9ed8\u8ba4\u7684\u5b57\u4f53\u540d plugins\/font\/plugin.js<br \/>\nconfig.font_defaultLabel = &#8216;Arial&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5b57\u4f53\u7f16\u8f91\u65f6\u7684\u5b57\u7b26\u96c6 \u53ef\u4ee5\u6dfb\u52a0\u5e38\u7528\u7684\u4e2d\u6587\u5b57\u7b26\uff1a\u5b8b\u4f53\u3001\u6977\u4f53\u3001\u9ed1\u4f53\u7b49 plugins\/font\/plugin.js<br \/>\nconfig.font_names = &#8216;Arial;Times New Roman;Verdana&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u6587\u5b57\u7684\u9ed8\u8ba4\u5f0f\u6837 plugins\/font\/plugin.js<br \/>\nconfig.font_style = {<br \/>\nelement&nbsp;&nbsp;  : &#8216;span&#8217;,<br \/>\nstyles&nbsp;&nbsp;  : { &#8216;font-family&#8217; : &#8216;#(family)&#8217; },<br \/>\noverrides : [ { element : &#8216;font&#8217;, attributes : { &#8216;face&#8217; : null } } ]<br \/>\n};<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5b57\u4f53\u9ed8\u8ba4\u5927\u5c0f plugins\/font\/plugin.js<br \/>\nconfig.fontSize_defaultLabel = &#8217;12px&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5b57\u4f53\u7f16\u8f91\u65f6\u53ef\u9009\u7684\u5b57\u4f53\u5927\u5c0f plugins\/font\/plugin.js<br \/>\nconfig.fontSize_sizes =&#8217;8\/8px;9\/9px;10\/10px;11\/11px;12\/12px;14\/14px;16\/16px;18\/18px;20\/20px;22\/22px;24\/24px;26\/26px;28\/28px;36\/36px;48\/48px;72\/72px&#8217;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8bbe\u7f6e\u5b57\u4f53\u5927\u5c0f\u65f6 \u4f7f\u7528\u7684\u5f0f\u6837 plugins\/font\/plugin.js<br \/>\nconfig.fontSize_style = {<br \/>\nelement&nbsp;&nbsp;  : &#8216;span&#8217;,<br \/>\nstyles&nbsp;&nbsp;  : { &#8216;font-size&#8217; : &#8216;#(size)&#8217; },<br \/>\noverrides : [ { element : &#8216;font&#8217;, attributes : { &#8216;size&#8217; : null } } ]<br \/>\n};<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u5f3a\u5236\u590d\u5236\u6765\u7684\u5185\u5bb9\u53bb\u9664\u683c\u5f0f plugins\/pastetext\/plugin.js<br \/>\nconfig.forcePasteAsPlainText =false \/\/\u4e0d\u53bb\u9664<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u5f3a\u5236\u7528&ldquo;&amp;&rdquo;\u6765\u4ee3\u66ff&ldquo;&amp;amp;&rdquo;plugins\/htmldataprocessor\/plugin.js<br \/>\nconfig.forceSimpleAmpersand = false;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9address\u6807\u7b7e\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_address = { element : &#8216;address&#8217;, attributes : { class : &#8216;styledAddress&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9DIV\u6807\u7b7e\u81ea\u52a8\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_div = { element : &#8216;div&#8217;, attributes : { class : &#8216;normalDiv&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9H1\u6807\u7b7e\u81ea\u52a8\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_h1 = { element : &#8216;h1&#8217;, attributes : { class : &#8216;contentTitle1&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9H2\u6807\u7b7e\u81ea\u52a8\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_h2 = { element : &#8216;h2&#8217;, attributes : { class : &#8216;contentTitle2&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9H3\u6807\u7b7e\u81ea\u52a8\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_h1 = { element : &#8216;h3&#8217;, attributes : { class : &#8216;contentTitle3&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9H4\u6807\u7b7e\u81ea\u52a8\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_h1 = { element : &#8216;h4&#8217;, attributes : { class : &#8216;contentTitle4&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9H5\u6807\u7b7e\u81ea\u52a8\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_h1 = { element : &#8216;h5&#8217;, attributes : { class : &#8216;contentTitle5&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9H6\u6807\u7b7e\u81ea\u52a8\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_h1 = { element : &#8216;h6&#8217;, attributes : { class : &#8216;contentTitle6&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9P\u6807\u7b7e\u81ea\u52a8\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_p = { element : &#8216;p&#8217;, attributes : { class : &#8216;normalPara&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9PRE\u6807\u7b7e\u81ea\u52a8\u8fdb\u884c\u683c\u5f0f\u5316 plugins\/format\/plugin.js<br \/>\nconfig.format_pre = { element : &#8216;pre&#8217;, attributes : { class : &#8216;code&#8217; } };<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u7528\u5206\u53f7\u5206\u9694\u7684\u6807\u7b7e\u540d\u5b57 \u5728\u5de5\u5177\u680f\u4e0a\u663e\u793a plugins\/format\/plugin.js<br \/>\nconfig.format_tags = &#8216;p;h1;h2;h3;h4;h5;h6;pre;address;div&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u4f7f\u7528\u5b8c\u6574\u7684html\u7f16\u8f91\u6a21\u5f0f \u5982\u4f7f\u7528\uff0c\u5176\u6e90\u7801\u5c06\u5305\u542b\uff1a&lt;html&gt;&lt;body&gt;&lt;\/body&gt;&lt;\/html&gt;\u7b49\u6807\u7b7e<br \/>\nconfig.fullPage = false;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u5ffd\u7565\u6bb5\u843d\u4e2d\u7684\u7a7a\u5b57\u7b26 \u82e5\u4e0d\u5ffd\u7565 \u5219\u5b57\u7b26\u5c06\u4ee5&ldquo;&rdquo;\u8868\u793a plugins\/wysiwygarea\/plugin.js<br \/>\nconfig.ignoreEmptyParagraph = true;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5728\u6e05\u9664\u56fe\u7247\u5c5e\u6027\u6846\u4e2d\u7684\u94fe\u63a5\u5c5e\u6027\u65f6 \u662f\u5426\u540c\u65f6\u6e05\u9664\u4e24\u8fb9\u7684&lt;a&gt;\u6807\u7b7e plugins\/image\/plugin.js<br \/>\nconfig.image_removeLinkByEmptyURL = true;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u4e00\u7ec4\u7528\u9017\u53f7\u5206\u9694\u7684\u6807\u7b7e\u540d\u79f0\uff0c\u663e\u793a\u5728\u5de6\u4e0b\u89d2\u7684\u5c42\u6b21\u5d4c\u5957\u4e2d plugins\/menu\/plugin.js.<br \/>\nconfig.menu_groups =&#8217;clipboard,form,tablecell,tablecellproperties,tablerow,tablecolumn,table,anchor,link,image,flash,checkbox,radio,textfield,hiddenfield,imagebutton,button,select,textarea&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u663e\u793a\u5b50\u83dc\u5355\u65f6\u7684\u5ef6\u8fdf\uff0c\u5355\u4f4d\uff1ams plugins\/menu\/plugin.js<br \/>\nconfig.menu_subMenuDelay = 400;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5f53\u6267\u884c&ldquo;\u65b0\u5efa&rdquo;\u547d\u4ee4\u65f6\uff0c\u7f16\u8f91\u5668\u4e2d\u7684\u5185\u5bb9 plugins\/newpage\/plugin.js<br \/>\nconfig.newpage_html = &#8221;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5f53\u4eceword\u91cc\u590d\u5236\u6587\u5b57\u8fdb\u6765\u65f6\uff0c\u662f\u5426\u8fdb\u884c\u6587\u5b57\u7684\u683c\u5f0f\u5316\u53bb\u9664 plugins\/pastefromword\/plugin.js<br \/>\nconfig.pasteFromWordIgnoreFontFace = true; \/\/\u9ed8\u8ba4\u4e3a\u5ffd\u7565\u683c\u5f0f<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u4f7f\u7528&lt;h1&gt;&lt;h2&gt;\u7b49\u6807\u7b7e\u4fee\u9970\u6216\u8005\u4ee3\u66ff\u4eceword\u6587\u6863\u4e2d\u7c98\u8d34\u8fc7\u6765\u7684\u5185\u5bb9 plugins\/pastefromword\/plugin.js<br \/>\nconfig.pasteFromWordKeepsStructure = false;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u4eceword\u4e2d\u7c98\u8d34\u5185\u5bb9\u65f6\u662f\u5426\u79fb\u9664\u683c\u5f0f plugins\/pastefromword\/plugin.js<br \/>\nconfig.pasteFromWordRemoveStyle = false;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9\u5e94\u540e\u53f0\u8bed\u8a00\u7684\u7c7b\u578b\u6765\u5bf9\u8f93\u51fa\u7684HTML\u5185\u5bb9\u8fdb\u884c\u683c\u5f0f\u5316\uff0c\u9ed8\u8ba4\u4e3a\u7a7a<br \/>\nconfig.protectedSource.push( \/&lt;\\?[\\s\\S]*?\\?&gt;\/g );&nbsp;&nbsp;  \/\/ PHP Code<br \/>\nconfig.protectedSource.push( \/\/g );&nbsp;&nbsp;  \/\/ ASP Code<br \/>\nconfig.protectedSource.push( \/(]+&gt;[\\s|\\S]*?&lt;\\\/asp:[^\\&gt;]+&gt;)|(]+\\\/&gt;)\/gi );&nbsp;&nbsp;  \/\/ ASP.Net Code<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5f53\u8f93\u5165\uff1ashift+Enter\u65f6\u63d2\u5165\u7684\u6807\u7b7e<br \/>\nconfig.shiftEnterMode = CKEDITOR.ENTER_P; \/\/\u53ef\u9009\uff1aCKEDITOR.ENTER_BR\u6216CKEDITOR.ENTER_DIV<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u53ef\u9009\u7684\u8868\u60c5\u66ff\u4ee3\u5b57\u7b26 plugins\/smiley\/plugin.js.<br \/>\nconfig.smiley_descriptions = [<br \/>\n&#8216;:)&#8217;, &#8216;:(&#8216;, &#8216;;)&#8217;, &#8216;:D&#8217;, &#8216;:\/&#8217;, &#8216;:P&#8217;,<br \/>\n&#8221;, &#8221;, &#8221;, &#8221;, &#8221;, &#8221;,<br \/>\n&#8221;, &#8216;;(&#8216;, &#8221;, &#8221;, &#8221;, &#8221;,<br \/>\n&#8221;, &#8216;:kiss&#8217;, &#8221; ];<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5bf9\u5e94\u7684\u8868\u60c5\u56fe\u7247 plugins\/smiley\/plugin.js<br \/>\nconfig.smiley_images = [<br \/>\n&#8216;regular_smile.gif&#8217;,&#8217;sad_smile.gif&#8217;,&#8217;wink_smile.gif&#8217;,&#8217;teeth_smile.gif&#8217;,&#8217;confused_smile.gif&#8217;,&#8217;tounge_smile.gif&#8217;,<br \/>\n&#8217;embaressed_smile.gif&#8217;,&#8217;omg_smile.gif&#8217;,&#8217;whatchutalkingabout_smile.gif&#8217;,&#8217;angry_smile.gif&#8217;,&#8217;angel_smile.gif&#8217;,&#8217;shades_smile.gif&#8217;,<br \/>\n&#8216;devil_smile.gif&#8217;,&#8217;cry_smile.gif&#8217;,&#8217;lightbulb.gif&#8217;,&#8217;thumbs_down.gif&#8217;,&#8217;thumbs_up.gif&#8217;,&#8217;heart.gif&#8217;,<br \/>\n&#8216;broken_heart.gif&#8217;,&#8217;kiss.gif&#8217;,&#8217;envelope.gif&#8217;];<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8868\u60c5\u7684\u5730\u5740 plugins\/smiley\/plugin.js<br \/>\nconfig.smiley_path = &#8216;plugins\/smiley\/images\/&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u9875\u9762\u8f7d\u5165\u65f6\uff0c\u7f16\u8f91\u6846\u662f\u5426\u7acb\u5373\u83b7\u5f97\u7126\u70b9 plugins\/editingblock\/plugin.js plugins\/editingblock\/plugin.js.<br \/>\nconfig.startupFocus = false;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8f7d\u5165\u65f6\uff0c\u4ee5\u4f55\u79cd\u65b9\u5f0f\u7f16\u8f91 \u6e90\u7801\u548c\u6240\u89c1\u5373\u6240\u5f97 &quot;source&quot;\u548c&quot;wysiwyg&quot; plugins\/editingblock\/plugin.js.<br \/>\nconfig.startupMode =&#8217;wysiwyg&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8f7d\u5165\u65f6\uff0c\u662f\u5426\u663e\u793a\u6846\u4f53\u7684\u8fb9\u6846 plugins\/showblocks\/plugin.js<br \/>\nconfig.startupOutlineBlocks = false;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u662f\u5426\u8f7d\u5165\u6837\u5f0f\u6587\u4ef6 plugins\/stylescombo\/plugin.js.<br \/>\nconfig.stylesCombo_stylesSet = &#8216;default&#8217;;<br \/>\n\/\/\u4ee5\u4e0b\u4e3a\u53ef\u9009<br \/>\nconfig.stylesCombo_stylesSet = &#8216;mystyles&#8217;;<br \/>\nconfig.stylesCombo_stylesSet = &#8216;mystyles:\/editorstyles\/styles.js&#8217;;<br \/>\nconfig.stylesCombo_stylesSet = &#8216;mystyles:http:\/\/www.example.com\/editorstyles\/styles.js&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u8d77\u59cb\u7684\u7d22\u5f15\u503c<br \/>\nconfig.tabIndex = 0;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5f53\u7528\u6237\u952e\u5165TAB\u65f6\uff0c\u7f16\u8f91\u5668\u8d70\u8fc7\u7684\u7a7a\u683c\u6570\uff0c(&amp;nbsp;) \u5f53\u503c\u4e3a0\u65f6\uff0c\u7126\u70b9\u5c06\u79fb\u51fa\u7f16\u8f91\u6846 plugins\/tab\/plugin.js<br \/>\nconfig.tabSpaces = 0;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u9ed8\u8ba4\u4f7f\u7528\u7684\u6a21\u677f plugins\/templates\/plugin.js.<br \/>\nconfig.templates = &#8216;default&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u7528\u9017\u53f7\u5206\u9694\u7684\u6a21\u677f\u6587\u4ef6plugins\/templates\/plugin.js.<br \/>\nconfig.templates_files = [ &#8216;plugins\/templates\/templates\/default.js&#8217; ]<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u5f53\u4f7f\u7528\u6a21\u677f\u65f6\uff0c&ldquo;\u7f16\u8f91\u5185\u5bb9\u5c06\u88ab\u66ff\u6362&rdquo;\u6846\u662f\u5426\u9009\u4e2d plugins\/templates\/plugin.js<br \/>\nconfig.templates_replaceContent = true;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u4e3b\u9898<br \/>\nconfig.theme = &#8216;default&#8217;;<\/p>\n<p>&nbsp;&nbsp;&nbsp;  \/\/\u64a4\u9500\u7684\u8bb0\u5f55\u6b65\u6570 plugins\/undo\/plugin.js<br \/>\nconfig.undoStackSize =20;<\/p>\n<p>\/\/ \u5728 CKEditor \u4e2d\u96c6\u6210 CKFinder\uff0c\u6ce8\u610f ckfinder \u7684\u8def\u5f84\u9009\u62e9\u8981\u6b63\u786e\u3002<br \/>\n\/\/CKFinder.SetupCKEditor(null, &#8216;\/ckfinder\/&#8217;);<\/p>\n<\/div>\n<p><\/body><\/html><\/p>\n","protected":false},"excerpt":{"rendered":"<p>CKEditor\u7684\u8be6\u7ec6\u914d\u7f6e CKEditor\u7684\u8be6\u7ec6\u914d\u7f6e \u4e00\u3001\u4f7f\u7528\u65b9\u6cd5\uff1a 1\u3001\u5728\u9875\u9762&lt;head&gt;\u4e2d\u5f15 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[],"class_list":["post-1229","post","type-post","status-publish","format-standard","hentry","category-code_related"],"_links":{"self":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts\/1229","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/comments?post=1229"}],"version-history":[{"count":0,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts\/1229\/revisions"}],"wp:attachment":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/media?parent=1229"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/categories?post=1229"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/tags?post=1229"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}