国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 編程 > PHP > 正文

phpcms-v9.6.0復制word格式文章到文本框

2019-11-08 00:47:46
字體:
來源:轉載
供稿:網友
CKEDITOR.editorConfig = function( config ){ // Define changes to default configuration here. For example: // config.language = 'fr'; config.uiColor = '#f7f5f4'; config.width = ''; config.removePlugins = 'elementspath,scayt'; config.disableNativeSpellChecker = false; config.resize_dir = 'vertical'; config.keystrokes =[[ CKEDITOR.CTRL + 13 /*Enter*/, 'maximize' ]]; config.extraPlugins = 'capture,videoforpc,Flashplayer'; config.enterMode = CKEDITOR.ENTER_BR; config.shiftEnterMode = CKEDITOR.ENTER_P; config.font_names='宋體/宋體;黑體/黑體;仿宋/仿宋_GB2312;楷體/楷體_GB2312;隸書/隸書;幼圓/幼圓;微軟雅黑/微軟雅黑;'+ config.font_names; config.allowedContent = true; //此處為Word格式配置區可修改 ******************************************************************************************** // 這里的意思是給p標簽設置class="MsoNormal" config.format_p = { element: 'p', attributes: { 'class': 'MsoNormal' } }; //config.pasteFromWordIgnoreFontFace = true; //默認為忽略格式 config.pasteFromWordRemoveFontStyles = false; config.pasteFromWordRemoveFontStyles = false; //控制是否去掉font config.pasteFromWordNumberedHeadingToList = true; //控制是否把word的列表轉換成html的list config.pasteFromWordRemoveStyles = false; //控制是否去掉styles //是否強制復制來的內容去除格式plugins/pastetext/plugin.js config.forcePasteasplainText =false//不去除 //對DIV標簽自動進行格式化 plugins/format/plugin.js config.format_div = { element : 'div', attributes : { class :'normalDiv' } }; //對H1標簽自動進行格式化 plugins/format/plugin.js config.format_h1 = { element : 'h1', attributes : { class :'contentTitle1' } }; //對H2標簽自動進行格式化 plugins/format/plugin.js config.format_h2 = { element : 'h2', attributes : { class :'contentTitle2' } }; //對H3標簽自動進行格式化 plugins/format/plugin.js //config.format_h1 = { element : 'h3', attributes : { class :'contentTitle3' } }; //對H4標簽自動進行格式化 plugins/format/plugin.js //config.format_h1 = { element : 'h4', attributes : { class :'contentTitle4' } }; //對H5標簽自動進行格式化 plugins/format/plugin.js //config.format_h1 = { element : 'h5', attributes : { class :'contentTitle5' } }; //對H6標簽自動進行格式化 plugins/format/plugin.js //config.format_h1 = { element : 'h6', attributes : { class :'contentTitle6' } }; //對P標簽自動進行格式化 plugins/format/plugin.js config.format_p = { element : 'p', attributes : { class : 'normalPara' }}; //對PRE標簽自動進行格式化 plugins/format/plugin.js config.format_pre = { element : 'pre', attributes : { class : 'code'} }; //用分號分隔的標簽名字 在工具欄上顯示plugins/format/plugin.js config.format_tags ='p;h1;h2;h3;h4;h5;h6;pre;address;div'; //是否使用完整的html編輯模式如使用,其源碼將包含:<html><body></body></html>等標簽 config.fullPage = false; //是否忽略段落中的空字符 若不忽略 則字符將以“”表示plugins/wysiwygarea/plugin.js config.ignoreEmptyParagraph = true; //在清除圖片屬性框中的鏈接屬性時 是否同時清除兩邊的<a>標簽plugins/image/plugin.js config.image_removeLinkByEmptyURL = true;********************************************************************************************//結束配置};CKEDITOR.on( 'instanceReady', function( ev ){ with (ev.editor.dataProcessor.writer) { setRules("p", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("h1", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("h2", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("h3", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("h4", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("h5", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("div", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("table", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("tr", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("td", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("iframe", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("li", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("ul", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); setRules("ol", {indent : false, breakAfterOpen : false, breakBeforeClose : false} ); } }); //CKEDITOR.plugins.load('pgrfilemanager');function insert_page(editorid){ var editor = CKEDITOR.instances[editorid]; editor.insertHtml('[page]'); if($('#paginationtype').val()) { $('#paginationtype').val(2); $('#paginationtype').CSS("color","red"); }}function insert_page_title(editorid,insertdata){ if(insertdata) { var editor = CKEDITOR.instances[editorid]; var data = editor.getData(); var page_title_value = $("#page_title_value").val(); if(page_title_value=='') { $("#msg_page_title_value").html("<font color='red'>請輸入子標題</font>"); return false; } page_title_value = '[page]'+page_title_value+'[/page]'; editor.insertHtml(page_title_value); $("#page_title_value").val(''); $("#msg_page_title_value").html(''); if($('#paginationtype').val()) { $('#paginationtype').val(2); $('#paginationtype').css("color","red"); } } else { $("#page_title_div").slideDown("fast"); }}var objid = MM_objid = key = 0;function file_list(fn,url,obj) { $('#MM_file_list_editor1').append('<div id="MM_file_list_'+fn+'">'+url+' <a href=/'#/' onMouSEOver=/'javascrJavascript:FilePreview("", 0);/'>查看</a> | <a href="javascript:insertHTMLToEditor(/'<img src='+url+'>/',/''+fn+'/')">插入</A> | <a href="javascript:del_file(/''+fn+'/',/''+url+'/','+fn+')">刪除</a><br>');}

注意保存原文件.


發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 葫芦岛市| 长兴县| 咸丰县| 定陶县| 辰溪县| 休宁县| 随州市| 赣州市| 朝阳县| 呼图壁县| 剑阁县| 昆明市| 石台县| 宁城县| 东源县| 宁强县| 乌鲁木齐县| 城口县| 普兰店市| 封丘县| 钟山县| 富民县| 铜梁县| 德化县| 芦溪县| 蕲春县| 普陀区| 乌鲁木齐市| 东乡族自治县| 涿鹿县| 迭部县| 建宁县| 珲春市| 丰城市| 昆山市| 剑川县| 乌鲁木齐县| 孝感市| 重庆市| 宜兰县| 延庆县|