From 59bfbce44674e52aefbe883233ffaea93d750a8f Mon Sep 17 00:00:00 2001 From: yujian <yujian@163.com> Date: 星期一, 25 十一月 2019 09:56:17 +0800 Subject: [PATCH] Merge branch 'div' of ssh://193.112.35.168:29418/fanli-server into div --- fanli/src/main/webapp/admin/new/js/ueditor.config.js | 992 +++++++++++++++++++++++++++++----------------------------- 1 files changed, 496 insertions(+), 496 deletions(-) diff --git a/fanli/src/main/webapp/admin/new/js/ueditor.config.js b/fanli/src/main/webapp/admin/new/js/ueditor.config.js index b7a1f3a..fc73c79 100644 --- a/fanli/src/main/webapp/admin/new/js/ueditor.config.js +++ b/fanli/src/main/webapp/admin/new/js/ueditor.config.js @@ -1,496 +1,496 @@ -/** - * ueditor瀹屾暣閰嶇疆椤� - * 鍙互鍦ㄨ繖閲岄厤缃暣涓紪杈戝櫒鐨勭壒鎬� - */ -/**************************鎻愮ず******************************** - * 鎵�鏈夎娉ㄩ噴鐨勯厤缃」鍧囦负UEditor榛樿鍊笺�� - * 淇敼榛樿閰嶇疆璇烽鍏堢‘淇濆凡缁忓畬鍏ㄦ槑纭鍙傛暟鐨勭湡瀹炵敤閫斻�� - * 涓昏鏈変袱绉嶄慨鏀规柟妗堬紝涓�绉嶆槸鍙栨秷姝ゅ娉ㄩ噴锛岀劧鍚庝慨鏀规垚瀵瑰簲鍙傛暟锛涘彟涓�绉嶆槸鍦ㄥ疄渚嬪寲缂栬緫鍣ㄦ椂浼犲叆瀵瑰簲鍙傛暟銆� - * 褰撳崌绾х紪杈戝櫒鏃讹紝鍙洿鎺ヤ娇鐢ㄦ棫鐗堥厤缃枃浠舵浛鎹㈡柊鐗堥厤缃枃浠�,涓嶇敤鎷呭績鏃х増閰嶇疆鏂囦欢涓洜缂哄皯鏂板姛鑳芥墍闇�鐨勫弬鏁拌�屽鑷磋剼鏈姤閿欍�� - **************************鎻愮ず********************************/ - -(function () { - - /** - * 缂栬緫鍣ㄨ祫婧愭枃浠舵牴璺緞銆傚畠鎵�琛ㄧず鐨勫惈涔夋槸锛氫互缂栬緫鍣ㄥ疄渚嬪寲椤甸潰涓哄綋鍓嶈矾寰勶紝鎸囧悜缂栬緫鍣ㄨ祫婧愭枃浠讹紙鍗砫ialog绛夋枃浠跺す锛夌殑璺緞銆� - * 閴翠簬寰堝鍚屽鍦ㄤ娇鐢ㄧ紪杈戝櫒鐨勬椂鍊欏嚭鐜扮殑绉嶇璺緞闂锛屾澶勫己鐑堝缓璁ぇ瀹朵娇鐢�"鐩稿浜庣綉绔欐牴鐩綍鐨勭浉瀵硅矾寰�"杩涜閰嶇疆銆� - * "鐩稿浜庣綉绔欐牴鐩綍鐨勭浉瀵硅矾寰�"涔熷氨鏄互鏂滄潬寮�澶寸殑褰㈠"/myProject/ueditor/"杩欐牱鐨勮矾寰勩�� - * 濡傛灉绔欑偣涓湁澶氫釜涓嶅湪鍚屼竴灞傜骇鐨勯〉闈㈤渶瑕佸疄渚嬪寲缂栬緫鍣紝涓斿紩鐢ㄤ簡鍚屼竴UEditor鐨勬椂鍊欙紝姝ゅ鐨刄RL鍙兘涓嶉�傜敤浜庢瘡涓〉闈㈢殑缂栬緫鍣ㄣ�� - * 鍥犳锛孶Editor鎻愪緵浜嗛拡瀵逛笉鍚岄〉闈㈢殑缂栬緫鍣ㄥ彲鍗曠嫭閰嶇疆鐨勬牴璺緞锛屽叿浣撴潵璇达紝鍦ㄩ渶瑕佸疄渚嬪寲缂栬緫鍣ㄧ殑椤甸潰鏈�椤堕儴鍐欎笂濡備笅浠g爜鍗冲彲銆傚綋鐒讹紝闇�瑕佷护姝ゅ鐨刄RL绛変簬瀵瑰簲鐨勯厤缃�� - * window.UEDITOR_HOME_URL = "/xxxx/xxxx/"; - */ - var URL = window.UEDITOR_HOME_URL || getUEBasePath(); - - /** - * 閰嶇疆椤逛富浣撱�傛敞鎰忥紝姝ゅ鎵�鏈夋秹鍙婂埌璺緞鐨勯厤缃埆閬楁紡URL鍙橀噺銆� - */ - window.UEDITOR_CONFIG = { - - //涓虹紪杈戝櫒瀹炰緥娣诲姞涓�涓矾寰勶紝杩欎釜涓嶈兘琚敞閲� - UEDITOR_HOME_URL: URL - - // 鏈嶅姟鍣ㄧ粺涓�璇锋眰鎺ュ彛璺緞 - , serverUrl: URL+'jsp/controller.jsp' - //宸ュ叿鏍忎笂鐨勬墍鏈夌殑鍔熻兘鎸夐挳鍜屼笅鎷夋锛屽彲浠ュ湪new缂栬緫鍣ㄧ殑瀹炰緥鏃堕�夋嫨鑷繁闇�瑕佺殑閲嶆柊瀹氫箟 - , toolbars: [[ - 'fullscreen', 'source', '|', 'undo', 'redo', '|', - 'bold', 'italic', 'underline', 'fontborder', 'strikethrough', 'superscript', 'subscript', 'removeformat', 'formatmatch', 'autotypeset', 'blockquote', 'pasteplain', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', 'selectall', 'cleardoc', '|', - 'rowspacingtop', 'rowspacingbottom', 'lineheight', '|', - 'customstyle', 'paragraph', 'fontfamily', 'fontsize', '|', - 'directionalityltr', 'directionalityrtl', 'indent', '|', - 'justifyleft', 'justifycenter', 'justifyright', 'justifyjustify', '|', 'touppercase', 'tolowercase', '|', - 'link', 'unlink', 'anchor', '|', 'imagenone', 'imageleft', 'imageright', 'imagecenter', '|', - 'simpleupload', 'insertimage', 'emotion', 'scrawl', 'insertvideo', 'music', 'attachment', 'map', 'gmap', 'insertframe', 'insertcode', 'webapp', 'pagebreak', 'template', 'background', '|', - 'horizontal', 'date', 'time', 'spechars', 'snapscreen', 'wordimage', '|', - 'inserttable', 'deletetable', 'insertparagraphbeforetable', 'insertrow', 'deleterow', 'insertcol', 'deletecol', 'mergecells', 'mergeright', 'mergedown', 'splittocells', 'splittorows', 'splittocols', 'charts', '|', - 'print', 'preview', 'searchreplace', 'drafts', 'help' - ]] - //褰撻紶鏍囨斁鍦ㄥ伐鍏锋爮涓婃椂鏄剧ず鐨則ooltip鎻愮ず,鐣欑┖鏀寔鑷姩澶氳瑷�閰嶇疆锛屽惁鍒欎互閰嶇疆鍊间负鍑� - //,labelMap:{ - // 'anchor':'', 'undo':'' - //} - - //璇█閰嶇疆椤�,榛樿鏄痾h-cn銆傛湁闇�瑕佺殑璇濅篃鍙互浣跨敤濡備笅杩欐牱鐨勬柟寮忔潵鑷姩澶氳瑷�鍒囨崲锛屽綋鐒讹紝鍓嶆彁鏉′欢鏄痩ang鏂囦欢澶逛笅瀛樺湪瀵瑰簲鐨勮瑷�鏂囦欢锛� - //lang鍊间篃鍙互閫氳繃鑷姩鑾峰彇 (navigator.language||navigator.browserLanguage ||navigator.userLanguage).toLowerCase() - //,lang:"zh-cn" - //,langPath:URL +"lang/" - - //涓婚閰嶇疆椤�,榛樿鏄痙efault銆傛湁闇�瑕佺殑璇濅篃鍙互浣跨敤濡備笅杩欐牱鐨勬柟寮忔潵鑷姩澶氫富棰樺垏鎹紝褰撶劧锛屽墠鎻愭潯浠舵槸themes鏂囦欢澶逛笅瀛樺湪瀵瑰簲鐨勪富棰樻枃浠讹細 - //鐜版湁濡備笅鐨偆:default - //,theme:'default' - //,themePath:URL +"themes/" - - //,zIndex : 900 //缂栬緫鍣ㄥ眰绾х殑鍩烘暟,榛樿鏄�900 - - //閽堝getAllHtml鏂规硶锛屼細鍦ㄥ搴旂殑head鏍囩涓鍔犺缂栫爜璁剧疆銆� - //,charset:"utf-8" - - //鑻ュ疄渚嬪寲缂栬緫鍣ㄧ殑椤甸潰鎵嬪姩淇敼鐨刣omain锛屾澶勯渶瑕佽缃负true - //,customDomain:false - - //甯哥敤閰嶇疆椤圭洰 - //,isShow : true //榛樿鏄剧ず缂栬緫鍣� - - //,textarea:'editorValue' // 鎻愪氦琛ㄥ崟鏃讹紝鏈嶅姟鍣ㄨ幏鍙栫紪杈戝櫒鎻愪氦鍐呭鐨勬墍鐢ㄧ殑鍙傛暟锛屽瀹炰緥鏃跺彲浠ョ粰瀹瑰櫒name灞炴�э紝浼氬皢name缁欏畾鐨勫�兼渶涓烘瘡涓疄渚嬬殑閿�硷紝涓嶇敤姣忔瀹炰緥鍖栫殑鏃跺�欓兘璁剧疆杩欎釜鍊� - - //,initialContent:'娆㈣繋浣跨敤ueditor!' //鍒濆鍖栫紪杈戝櫒鐨勫唴瀹�,涔熷彲浠ラ�氳繃textarea/script缁欏�硷紝鐪嬪畼缃戜緥瀛� - - //,autoClearinitialContent:true //鏄惁鑷姩娓呴櫎缂栬緫鍣ㄥ垵濮嬪唴瀹癸紝娉ㄦ剰锛氬鏋渇ocus灞炴�ц缃负true,杩欎釜涔熶负鐪燂紝閭d箞缂栬緫鍣ㄤ竴涓婃潵灏变細瑙﹀彂瀵艰嚧鍒濆鍖栫殑鍐呭鐪嬩笉鍒颁簡 - - //,focus:false //鍒濆鍖栨椂锛屾槸鍚﹁缂栬緫鍣ㄨ幏寰楃劍鐐箃rue鎴杅alse - - //濡傛灉鑷畾涔夛紝鏈�濂界粰p鏍囩濡備笅鐨勮楂橈紝瑕佷笉杈撳叆涓枃鏃讹紝浼氭湁璺冲姩鎰� - //,initialStyle:'p{line-height:1em}'//缂栬緫鍣ㄥ眰绾х殑鍩烘暟,鍙互鐢ㄦ潵鏀瑰彉瀛椾綋绛� - - //,iframeCssUrl: URL + '/themes/iframe.css' //缁欑紪杈戝尯鍩熺殑iframe寮曞叆涓�涓猚ss鏂囦欢 - - //indentValue - //棣栬缂╄繘璺濈,榛樿鏄�2em - //,indentValue:'2em' - - //,initialFrameWidth:1000 //鍒濆鍖栫紪杈戝櫒瀹藉害,榛樿1000 - //,initialFrameHeight:320 //鍒濆鍖栫紪杈戝櫒楂樺害,榛樿320 - - //,readonly : false //缂栬緫鍣ㄥ垵濮嬪寲缁撴潫鍚�,缂栬緫鍖哄煙鏄惁鏄彧璇荤殑锛岄粯璁ゆ槸false - - //,autoClearEmptyNode : true //getContent鏃讹紝鏄惁鍒犻櫎绌虹殑inlineElement鑺傜偣锛堝寘鎷祵濂楃殑鎯呭喌锛� - - //鍚敤鑷姩淇濆瓨 - //,enableAutoSave: true - //鑷姩淇濆瓨闂撮殧鏃堕棿锛� 鍗曚綅ms - //,saveInterval: 500 - - //,fullscreen : false //鏄惁寮�鍚垵濮嬪寲鏃跺嵆鍏ㄥ睆锛岄粯璁ゅ叧闂� - - //,imagePopup:true //鍥剧墖鎿嶄綔鐨勬诞灞傚紑鍏筹紝榛樿鎵撳紑 - - //,autoSyncData:true //鑷姩鍚屾缂栬緫鍣ㄨ鎻愪氦鐨勬暟鎹� - //,emotionLocalization:false //鏄惁寮�鍚〃鎯呮湰鍦板寲锛岄粯璁ゅ叧闂�傝嫢瑕佸紑鍚纭繚emotion鏂囦欢澶逛笅鍖呭惈瀹樼綉鎻愪緵鐨刬mages琛ㄦ儏鏂囦欢澶� - - //绮樿创鍙繚鐣欐爣绛撅紝鍘婚櫎鏍囩鎵�鏈夊睘鎬� - //,retainOnlyLabelPasted: false - - //,pasteplain:false //鏄惁榛樿涓虹函鏂囨湰绮樿创銆俧alse涓轰笉浣跨敤绾枃鏈矘璐达紝true涓轰娇鐢ㄧ函鏂囨湰绮樿创 - //绾枃鏈矘璐存ā寮忎笅鐨勮繃婊よ鍒� - //'filterTxtRules' : function(){ - // function transP(node){ - // node.tagName = 'p'; - // node.setStyle(); - // } - // return { - // //鐩存帴鍒犻櫎鍙婂叾瀛楄妭鐐瑰唴瀹� - // '-' : 'script style object iframe embed input select', - // 'p': {$:{}}, - // 'br':{$:{}}, - // 'div':{'$':{}}, - // 'li':{'$':{}}, - // 'caption':transP, - // 'th':transP, - // 'tr':transP, - // 'h1':transP,'h2':transP,'h3':transP,'h4':transP,'h5':transP,'h6':transP, - // 'td':function(node){ - // //娌℃湁鍐呭鐨則d鐩存帴鍒犳帀 - // var txt = !!node.innerText(); - // if(txt){ - // node.parentNode.insertAfter(UE.uNode.createText(' '),node); - // } - // node.parentNode.removeChild(node,node.innerText()) - // } - // } - //}() - - //,allHtmlEnabled:false //鎻愪氦鍒板悗鍙扮殑鏁版嵁鏄惁鍖呭惈鏁翠釜html瀛楃涓� - - //insertorderedlist - //鏈夊簭鍒楄〃鐨勪笅鎷夐厤缃�,鍊肩暀绌烘椂鏀寔澶氳瑷�鑷姩璇嗗埆锛岃嫢閰嶇疆鍊硷紝鍒欎互姝ゅ�间负鍑� - //,'insertorderedlist':{ - // //鑷畾鐨勬牱寮� - // 'num':'1,2,3...', - // 'num1':'1),2),3)...', - // 'num2':'(1),(2),(3)...', - // 'cn':'涓�,浜�,涓�....', - // 'cn1':'涓�),浜�),涓�)....', - // 'cn2':'(涓�),(浜�),(涓�)....', - // //绯荤粺鑷甫 - // 'decimal' : '' , //'1,2,3...' - // 'lower-alpha' : '' , // 'a,b,c...' - // 'lower-roman' : '' , //'i,ii,iii...' - // 'upper-alpha' : '' , lang //'A,B,C' - // 'upper-roman' : '' //'I,II,III...' - //} - - //insertunorderedlist - //鏃犲簭鍒楄〃鐨勪笅鎷夐厤缃紝鍊肩暀绌烘椂鏀寔澶氳瑷�鑷姩璇嗗埆锛岃嫢閰嶇疆鍊硷紝鍒欎互姝ゅ�间负鍑� - //,insertunorderedlist : { //鑷畾鐨勬牱寮� - // 'dash' :'鈥� 鐮存姌鍙�', //-鐮存姌鍙� - // 'dot':' 銆� 灏忓渾鍦�', //绯荤粺鑷甫 - // 'circle' : '', // '鈼� 灏忓渾鍦�' - // 'disc' : '', // '鈼� 灏忓渾鐐�' - // 'square' : '' //'鈻� 灏忔柟鍧�' - //} - //,listDefaultPaddingLeft : '30'//榛樿鐨勫乏杈圭缉杩涚殑鍩烘暟鍊� - //,listiconpath : 'http://bs.baidu.com/listicon/'//鑷畾涔夋爣鍙风殑璺緞 - //,maxListLevel : 3 //闄愬埗鍙互tab鐨勭骇鏁�, 璁剧疆-1涓轰笉闄愬埗 - - //,autoTransWordToList:false //绂佹word涓矘璐磋繘鏉ョ殑鍒楄〃鑷姩鍙樻垚鍒楄〃鏍囩 - - //fontfamily - //瀛椾綋璁剧疆 label鐣欑┖鏀寔澶氳瑷�鑷姩鍒囨崲锛岃嫢閰嶇疆锛屽垯浠ラ厤缃�间负鍑� - //,'fontfamily':[ - // { label:'',name:'songti',val:'瀹嬩綋,SimSun'}, - // { label:'',name:'kaiti',val:'妤蜂綋,妤蜂綋_GB2312, SimKai'}, - // { label:'',name:'yahei',val:'寰蒋闆呴粦,Microsoft YaHei'}, - // { label:'',name:'heiti',val:'榛戜綋, SimHei'}, - // { label:'',name:'lishu',val:'闅朵功, SimLi'}, - // { label:'',name:'andaleMono',val:'andale mono'}, - // { label:'',name:'arial',val:'arial, helvetica,sans-serif'}, - // { label:'',name:'arialBlack',val:'arial black,avant garde'}, - // { label:'',name:'comicSansMs',val:'comic sans ms'}, - // { label:'',name:'impact',val:'impact,chicago'}, - // { label:'',name:'timesNewRoman',val:'times new roman'} - //] - - //fontsize - //瀛楀彿 - //,'fontsize':[10, 11, 12, 14, 16, 18, 20, 24, 36] - - //paragraph - //娈佃惤鏍煎紡 鍊肩暀绌烘椂鏀寔澶氳瑷�鑷姩璇嗗埆锛岃嫢閰嶇疆锛屽垯浠ラ厤缃�间负鍑� - //,'paragraph':{'p':'', 'h1':'', 'h2':'', 'h3':'', 'h4':'', 'h5':'', 'h6':''} - - //rowspacingtop - //娈甸棿璺� 鍊煎拰鏄剧ず鐨勫悕瀛楃浉鍚� - //,'rowspacingtop':['5', '10', '15', '20', '25'] - - //rowspacingBottom - //娈甸棿璺� 鍊煎拰鏄剧ず鐨勫悕瀛楃浉鍚� - //,'rowspacingbottom':['5', '10', '15', '20', '25'] - - //lineheight - //琛屽唴闂磋窛 鍊煎拰鏄剧ず鐨勫悕瀛楃浉鍚� - //,'lineheight':['1', '1.5','1.75','2', '3', '4', '5'] - - //customstyle - //鑷畾涔夋牱寮忥紝涓嶆敮鎸佸浗闄呭寲锛屾澶勯厤缃�煎嵆鍙渶鍚庢樉绀哄�� - //block鐨勫厓绱犳槸渚濇嵁璁剧疆娈佃惤鐨勯�昏緫璁剧疆鐨勶紝inline鐨勫厓绱犱緷鎹瓸IU鐨勯�昏緫璁剧疆 - //灏介噺浣跨敤涓�浜涘父鐢ㄧ殑鏍囩 - //鍙傛暟璇存槑 - //tag 浣跨敤鐨勬爣绛惧悕瀛� - //label 鏄剧ず鐨勫悕瀛椾篃鏄敤鏉ユ爣璇嗕笉鍚岀被鍨嬬殑鏍囪瘑绗︼紝娉ㄦ剰杩欎釜鍊兼瘡涓涓嶅悓锛� - //style 娣诲姞鐨勬牱寮� - //姣忎竴涓璞″氨鏄竴涓嚜瀹氫箟鐨勬牱寮� - //,'customstyle':[ - // {tag:'h1', name:'tc', label:'', style:'border-bottom:#ccc 2px solid;padding:0 4px 0 0;text-align:center;margin:0 0 20px 0;'}, - // {tag:'h1', name:'tl',label:'', style:'border-bottom:#ccc 2px solid;padding:0 4px 0 0;margin:0 0 10px 0;'}, - // {tag:'span',name:'im', label:'', style:'font-style:italic;font-weight:bold'}, - // {tag:'span',name:'hi', label:'', style:'font-style:italic;font-weight:bold;color:rgb(51, 153, 204)'} - //] - - //鎵撳紑鍙抽敭鑿滃崟鍔熻兘 - //,enableContextMenu: true - //鍙抽敭鑿滃崟鐨勫唴瀹癸紝鍙互鍙傝�僷lugins/contextmenu.js閲岃竟鐨勯粯璁よ彍鍗曠殑渚嬪瓙锛宭abel鐣欑┖鏀寔鍥介檯鍖栵紝鍚﹀垯浠ユ閰嶇疆涓哄噯 - //,contextMenu:[ - // { - // label:'', //鏄剧ず鐨勫悕绉� - // cmdName:'selectall',//鎵ц鐨刢ommand鍛戒护锛屽綋鐐瑰嚮杩欎釜鍙抽敭鑿滃崟鏃� - // //exec鍙�夛紝鏈変簡exec灏变細鍦ㄧ偣鍑绘椂鎵ц杩欎釜function锛屼紭鍏堢骇楂樹簬cmdName - // exec:function () { - // //this鏄綋鍓嶇紪杈戝櫒鐨勫疄渚� - // //this.ui._dialogs['inserttableDialog'].open(); - // } - // } - //] - - //蹇嵎鑿滃崟 - //,shortcutMenu:["fontfamily", "fontsize", "bold", "italic", "underline", "forecolor", "backcolor", "insertorderedlist", "insertunorderedlist"] - - //elementPathEnabled - //鏄惁鍚敤鍏冪礌璺緞锛岄粯璁ゆ槸鏄剧ず - //,elementPathEnabled : true - - //wordCount - //,wordCount:true //鏄惁寮�鍚瓧鏁扮粺璁� - //,maximumWords:10000 //鍏佽鐨勬渶澶у瓧绗︽暟 - //瀛楁暟缁熻鎻愮ず锛寋#count}浠h〃褰撳墠瀛楁暟锛寋#leave}浠h〃杩樺彲浠ヨ緭鍏ュ灏戝瓧绗︽暟,鐣欑┖鏀寔澶氳瑷�鑷姩鍒囨崲锛屽惁鍒欐寜姝ら厤缃樉绀� - //,wordCountMsg:'' //褰撳墠宸茶緭鍏� {#count} 涓瓧绗︼紝鎮ㄨ繕鍙互杈撳叆{#leave} 涓瓧绗� - //瓒呭嚭瀛楁暟闄愬埗鎻愮ず 鐣欑┖鏀寔澶氳瑷�鑷姩鍒囨崲锛屽惁鍒欐寜姝ら厤缃樉绀� - //,wordOverFlowMsg:'' //<span style="color:red;">浣犺緭鍏ョ殑瀛楃涓暟宸茬粡瓒呭嚭鏈�澶у厑璁稿�硷紝鏈嶅姟鍣ㄥ彲鑳戒細鎷掔粷淇濆瓨锛�</span> - - //tab - //鐐瑰嚮tab閿椂绉诲姩鐨勮窛绂�,tabSize鍊嶆暟锛宼abNode浠�涔堝瓧绗﹀仛涓哄崟浣� - //,tabSize:4 - //,tabNode:' ' - - //removeFormat - //娓呴櫎鏍煎紡鏃跺彲浠ュ垹闄ょ殑鏍囩鍜屽睘鎬� - //removeForamtTags鏍囩 - //,removeFormatTags:'b,big,code,del,dfn,em,font,i,ins,kbd,q,samp,small,span,strike,strong,sub,sup,tt,u,var' - //removeFormatAttributes灞炴�� - //,removeFormatAttributes:'class,style,lang,width,height,align,hspace,valign' - - //undo - //鍙互鏈�澶氬洖閫�鐨勬鏁�,榛樿20 - //,maxUndoCount:20 - //褰撹緭鍏ョ殑瀛楃鏁拌秴杩囪鍊兼椂锛屼繚瀛樹竴娆$幇鍦� - //,maxInputCount:1 - - //autoHeightEnabled - // 鏄惁鑷姩闀块珮,榛樿true - //,autoHeightEnabled:true - - //scaleEnabled - //鏄惁鍙互鎷変几闀块珮,榛樿true(褰撳紑鍚椂锛岃嚜鍔ㄩ暱楂樺け鏁�) - //,scaleEnabled:false - //,minFrameWidth:800 //缂栬緫鍣ㄦ嫋鍔ㄦ椂鏈�灏忓搴�,榛樿800 - //,minFrameHeight:220 //缂栬緫鍣ㄦ嫋鍔ㄦ椂鏈�灏忛珮搴�,榛樿220 - - //autoFloatEnabled - //鏄惁淇濇寔toolbar鐨勪綅缃笉鍔�,榛樿true - //,autoFloatEnabled:true - //娴姩鏃跺伐鍏锋爮璺濈娴忚鍣ㄩ《閮ㄧ殑楂樺害锛岀敤浜庢煇浜涘叿鏈夊浐瀹氬ご閮ㄧ殑椤甸潰 - //,topOffset:30 - //缂栬緫鍣ㄥ簳閮ㄨ窛绂诲伐鍏锋爮楂樺害(濡傛灉鍙傛暟澶т簬绛変簬缂栬緫鍣ㄩ珮搴︼紝鍒欒缃棤鏁�) - //,toolbarTopOffset:400 - - //璁剧疆杩滅▼鍥剧墖鏄惁鎶撳彇鍒版湰鍦颁繚瀛� - //,catchRemoteImageEnable: true //璁剧疆鏄惁鎶撳彇杩滅▼鍥剧墖 - - //pageBreakTag - //鍒嗛〉鏍囪瘑绗�,榛樿鏄痏ueditor_page_break_tag_ - //,pageBreakTag:'_ueditor_page_break_tag_' - - //autotypeset - //鑷姩鎺掔増鍙傛暟 - //,autotypeset: { - // mergeEmptyline: true, //鍚堝苟绌鸿 - // removeClass: true, //鍘绘帀鍐椾綑鐨刢lass - // removeEmptyline: false, //鍘绘帀绌鸿 - // textAlign:"left", //娈佃惤鐨勬帓鐗堟柟寮忥紝鍙互鏄� left,right,center,justify 鍘绘帀杩欎釜灞炴�ц〃绀轰笉鎵ц鎺掔増 - // imageBlockLine: 'center', //鍥剧墖鐨勬诞鍔ㄦ柟寮忥紝鐙崰涓�琛屽墽涓�,宸﹀彸娴姩锛岄粯璁�: center,left,right,none 鍘绘帀杩欎釜灞炴�ц〃绀轰笉鎵ц鎺掔増 - // pasteFilter: false, //鏍规嵁瑙勫垯杩囨护娌′簨绮樿创杩涙潵鐨勫唴瀹� - // clearFontSize: false, //鍘绘帀鎵�鏈夌殑鍐呭祵瀛楀彿锛屼娇鐢ㄧ紪杈戝櫒榛樿鐨勫瓧鍙� - // clearFontFamily: false, //鍘绘帀鎵�鏈夌殑鍐呭祵瀛椾綋锛屼娇鐢ㄧ紪杈戝櫒榛樿鐨勫瓧浣� - // removeEmptyNode: false, // 鍘绘帀绌鸿妭鐐� - // //鍙互鍘绘帀鐨勬爣绛� - // removeTagNames: {鏍囩鍚嶅瓧:1}, - // indent: false, // 琛岄缂╄繘 - // indentValue : '2em', //琛岄缂╄繘鐨勫ぇ灏� - // bdc2sb: false, - // tobdc: false - //} - - //tableDragable - //琛ㄦ牸鏄惁鍙互鎷栨嫿 - //,tableDragable: true - - - - //sourceEditor - //婧愮爜鐨勬煡鐪嬫柟寮�,codemirror 鏄唬鐮侀珮浜紝textarea鏄枃鏈,榛樿鏄痗odemirror - //娉ㄦ剰榛樿codemirror鍙兘鍦╥e8+鍜岄潪ie涓娇鐢� - //,sourceEditor:"codemirror" - //濡傛灉sourceEditor鏄痗odemirror锛岃繕鐢ㄩ厤缃竴涓嬩袱涓弬鏁� - //codeMirrorJsUrl js鍔犺浇鐨勮矾寰勶紝榛樿鏄� URL + "third-party/codemirror/codemirror.js" - //,codeMirrorJsUrl:URL + "third-party/codemirror/codemirror.js" - //codeMirrorCssUrl css鍔犺浇鐨勮矾寰勶紝榛樿鏄� URL + "third-party/codemirror/codemirror.css" - //,codeMirrorCssUrl:URL + "third-party/codemirror/codemirror.css" - //缂栬緫鍣ㄥ垵濮嬪寲瀹屾垚鍚庢槸鍚﹁繘鍏ユ簮鐮佹ā寮忥紝榛樿涓哄惁銆� - //,sourceEditorFirst:false - - //iframeUrlMap - //dialog鍐呭鐨勮矾寰� 锝炰細琚浛鎹㈡垚URL,鍨撳睘鎬т竴鏃︽墦寮�锛屽皢瑕嗙洊鎵�鏈夌殑dialog鐨勯粯璁よ矾寰� - //,iframeUrlMap:{ - // 'anchor':'~/dialogs/anchor/anchor.html', - //} - - //allowLinkProtocol 鍏佽鐨勯摼鎺ュ湴鍧�锛屾湁杩欎簺鍓嶇紑鐨勯摼鎺ュ湴鍧�涓嶄細鑷姩娣诲姞http - //, allowLinkProtocols: ['http:', 'https:', '#', '/', 'ftp:', 'mailto:', 'tel:', 'git:', 'svn:'] - - //webAppKey 鐧惧害搴旂敤鐨凙PIkey锛屾瘡涓珯闀垮繀椤婚鍏堝幓鐧惧害瀹樼綉娉ㄥ唽涓�涓猭ey鍚庢柟鑳芥甯镐娇鐢╝pp鍔熻兘锛屾敞鍐屼粙缁嶏紝http://app.baidu.com/static/cms/getapikey.html - //, webAppKey: "" - - //榛樿杩囨护瑙勫垯鐩稿叧閰嶇疆椤圭洰 - //,disabledTableInTable:true //绂佹琛ㄦ牸宓屽 - //,allowDivTransToP:true //鍏佽杩涘叆缂栬緫鍣ㄧ殑div鏍囩鑷姩鍙樻垚p鏍囩 - //,rgb2Hex:true //榛樿浜у嚭鐨勬暟鎹腑鐨刢olor鑷姩浠巖gb鏍煎紡鍙樻垚16杩涘埗鏍煎紡 - - // xss 杩囨护鏄惁寮�鍚�,inserthtml绛夋搷浣� - ,xssFilterRules: true - //input xss杩囨护 - ,inputXssFilter: true - //output xss杩囨护 - ,outputXssFilter: true - // xss杩囨护鐧藉悕鍗� 鍚嶅崟鏉ユ簮: https://raw.githubusercontent.com/leizongmin/js-xss/master/lib/default.js - ,whitList: { - a: ['target', 'href', 'title', 'class', 'style'], - abbr: ['title', 'class', 'style'], - address: ['class', 'style'], - area: ['shape', 'coords', 'href', 'alt'], - article: [], - aside: [], - audio: ['autoplay', 'controls', 'loop', 'preload', 'src', 'class', 'style'], - b: ['class', 'style'], - bdi: ['dir'], - bdo: ['dir'], - big: [], - blockquote: ['cite', 'class', 'style'], - br: [], - caption: ['class', 'style'], - center: [], - cite: [], - code: ['class', 'style'], - col: ['align', 'valign', 'span', 'width', 'class', 'style'], - colgroup: ['align', 'valign', 'span', 'width', 'class', 'style'], - dd: ['class', 'style'], - del: ['datetime'], - details: ['open'], - div: ['class', 'style'], - dl: ['class', 'style'], - dt: ['class', 'style'], - em: ['class', 'style'], - font: ['color', 'size', 'face'], - footer: [], - h1: ['class', 'style'], - h2: ['class', 'style'], - h3: ['class', 'style'], - h4: ['class', 'style'], - h5: ['class', 'style'], - h6: ['class', 'style'], - header: [], - hr: [], - i: ['class', 'style'], - img: ['src', 'alt', 'title', 'width', 'height', 'id', '_src', 'loadingclass', 'class', 'data-latex'], - ins: ['datetime'], - li: ['class', 'style'], - mark: [], - nav: [], - ol: ['class', 'style'], - p: ['class', 'style'], - pre: ['class', 'style'], - s: [], - section:[], - small: [], - span: ['class', 'style'], - sub: ['class', 'style'], - sup: ['class', 'style'], - strong: ['class', 'style'], - table: ['width', 'border', 'align', 'valign', 'class', 'style'], - tbody: ['align', 'valign', 'class', 'style'], - td: ['width', 'rowspan', 'colspan', 'align', 'valign', 'class', 'style'], - tfoot: ['align', 'valign', 'class', 'style'], - th: ['width', 'rowspan', 'colspan', 'align', 'valign', 'class', 'style'], - thead: ['align', 'valign', 'class', 'style'], - tr: ['rowspan', 'align', 'valign', 'class', 'style'], - tt: [], - u: [], - ul: ['class', 'style'], - video: ['autoplay', 'controls', 'loop', 'preload', 'src', 'height', 'width', 'class', 'style'] - } - }; - - function getUEBasePath(docUrl, confUrl) { - - return getBasePath(docUrl || self.document.URL || self.location.href, confUrl || getConfigFilePath()); - - } - - function getConfigFilePath() { - - var configPath = document.getElementsByTagName('script'); - - return configPath[ configPath.length - 1 ].src; - - } - - function getBasePath(docUrl, confUrl) { - - var basePath = confUrl; - - - if (/^(\/|\\\\)/.test(confUrl)) { - - basePath = /^.+?\w(\/|\\\\)/.exec(docUrl)[0] + confUrl.replace(/^(\/|\\\\)/, ''); - - } else if (!/^[a-z]+:/i.test(confUrl)) { - - docUrl = docUrl.split("#")[0].split("?")[0].replace(/[^\\\/]+$/, ''); - - basePath = docUrl + "" + confUrl; - - } - - return optimizationPath(basePath); - - } - - function optimizationPath(path) { - - var protocol = /^[a-z]+:\/\//.exec(path)[ 0 ], - tmp = null, - res = []; - - path = path.replace(protocol, "").split("?")[0].split("#")[0]; - - path = path.replace(/\\/g, '/').split(/\//); - - path[ path.length - 1 ] = ""; - - while (path.length) { - - if (( tmp = path.shift() ) === "..") { - res.pop(); - } else if (tmp !== ".") { - res.push(tmp); - } - - } - - return protocol + res.join("/"); - - } - - window.UE = { - getUEBasePath: getUEBasePath - }; - -})(); +/** + * ueditor瀹屾暣閰嶇疆椤� + * 鍙互鍦ㄨ繖閲岄厤缃暣涓紪杈戝櫒鐨勭壒鎬� + */ +/**************************鎻愮ず******************************** + * 鎵�鏈夎娉ㄩ噴鐨勯厤缃」鍧囦负UEditor榛樿鍊笺�� + * 淇敼榛樿閰嶇疆璇烽鍏堢‘淇濆凡缁忓畬鍏ㄦ槑纭鍙傛暟鐨勭湡瀹炵敤閫斻�� + * 涓昏鏈変袱绉嶄慨鏀规柟妗堬紝涓�绉嶆槸鍙栨秷姝ゅ娉ㄩ噴锛岀劧鍚庝慨鏀规垚瀵瑰簲鍙傛暟锛涘彟涓�绉嶆槸鍦ㄥ疄渚嬪寲缂栬緫鍣ㄦ椂浼犲叆瀵瑰簲鍙傛暟銆� + * 褰撳崌绾х紪杈戝櫒鏃讹紝鍙洿鎺ヤ娇鐢ㄦ棫鐗堥厤缃枃浠舵浛鎹㈡柊鐗堥厤缃枃浠�,涓嶇敤鎷呭績鏃х増閰嶇疆鏂囦欢涓洜缂哄皯鏂板姛鑳芥墍闇�鐨勫弬鏁拌�屽鑷磋剼鏈姤閿欍�� + **************************鎻愮ず********************************/ + +(function () { + + /** + * 缂栬緫鍣ㄨ祫婧愭枃浠舵牴璺緞銆傚畠鎵�琛ㄧず鐨勫惈涔夋槸锛氫互缂栬緫鍣ㄥ疄渚嬪寲椤甸潰涓哄綋鍓嶈矾寰勶紝鎸囧悜缂栬緫鍣ㄨ祫婧愭枃浠讹紙鍗砫ialog绛夋枃浠跺す锛夌殑璺緞銆� + * 閴翠簬寰堝鍚屽鍦ㄤ娇鐢ㄧ紪杈戝櫒鐨勬椂鍊欏嚭鐜扮殑绉嶇璺緞闂锛屾澶勫己鐑堝缓璁ぇ瀹朵娇鐢�"鐩稿浜庣綉绔欐牴鐩綍鐨勭浉瀵硅矾寰�"杩涜閰嶇疆銆� + * "鐩稿浜庣綉绔欐牴鐩綍鐨勭浉瀵硅矾寰�"涔熷氨鏄互鏂滄潬寮�澶寸殑褰㈠"/myProject/ueditor/"杩欐牱鐨勮矾寰勩�� + * 濡傛灉绔欑偣涓湁澶氫釜涓嶅湪鍚屼竴灞傜骇鐨勯〉闈㈤渶瑕佸疄渚嬪寲缂栬緫鍣紝涓斿紩鐢ㄤ簡鍚屼竴UEditor鐨勬椂鍊欙紝姝ゅ鐨刄RL鍙兘涓嶉�傜敤浜庢瘡涓〉闈㈢殑缂栬緫鍣ㄣ�� + * 鍥犳锛孶Editor鎻愪緵浜嗛拡瀵逛笉鍚岄〉闈㈢殑缂栬緫鍣ㄥ彲鍗曠嫭閰嶇疆鐨勬牴璺緞锛屽叿浣撴潵璇达紝鍦ㄩ渶瑕佸疄渚嬪寲缂栬緫鍣ㄧ殑椤甸潰鏈�椤堕儴鍐欎笂濡備笅浠g爜鍗冲彲銆傚綋鐒讹紝闇�瑕佷护姝ゅ鐨刄RL绛変簬瀵瑰簲鐨勯厤缃�� + * window.UEDITOR_HOME_URL = "/xxxx/xxxx/"; + */ + var URL = window.UEDITOR_HOME_URL || getUEBasePath(); + + /** + * 閰嶇疆椤逛富浣撱�傛敞鎰忥紝姝ゅ鎵�鏈夋秹鍙婂埌璺緞鐨勯厤缃埆閬楁紡URL鍙橀噺銆� + */ + window.UEDITOR_CONFIG = { + + //涓虹紪杈戝櫒瀹炰緥娣诲姞涓�涓矾寰勶紝杩欎釜涓嶈兘琚敞閲� + UEDITOR_HOME_URL: URL + + // 鏈嶅姟鍣ㄧ粺涓�璇锋眰鎺ュ彛璺緞 + , serverUrl: URL+'jsp/controller.jsp' + //宸ュ叿鏍忎笂鐨勬墍鏈夌殑鍔熻兘鎸夐挳鍜屼笅鎷夋锛屽彲浠ュ湪new缂栬緫鍣ㄧ殑瀹炰緥鏃堕�夋嫨鑷繁闇�瑕佺殑閲嶆柊瀹氫箟 + , toolbars: [[ + 'fullscreen', 'source', '|', 'undo', 'redo', '|', + 'bold', 'italic', 'underline', 'fontborder', 'strikethrough', 'superscript', 'subscript', 'removeformat', 'formatmatch', 'autotypeset', 'blockquote', 'pasteplain', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', 'selectall', 'cleardoc', '|', + 'rowspacingtop', 'rowspacingbottom', 'lineheight', '|', + 'customstyle', 'paragraph', 'fontfamily', 'fontsize', '|', + 'directionalityltr', 'directionalityrtl', 'indent', '|', + 'justifyleft', 'justifycenter', 'justifyright', 'justifyjustify', '|', 'touppercase', 'tolowercase', '|', + 'link', 'unlink', 'anchor', '|', 'imagenone', 'imageleft', 'imageright', 'imagecenter', '|', + 'simpleupload', 'insertimage', 'emotion', 'scrawl', 'insertvideo', 'music', 'attachment', 'map', 'gmap', 'insertframe', 'insertcode', 'webapp', 'pagebreak', 'template', 'background', '|', + 'horizontal', 'date', 'time', 'spechars', 'snapscreen', 'wordimage', '|', + 'inserttable', 'deletetable', 'insertparagraphbeforetable', 'insertrow', 'deleterow', 'insertcol', 'deletecol', 'mergecells', 'mergeright', 'mergedown', 'splittocells', 'splittorows', 'splittocols', 'charts', '|', + 'print', 'preview', 'searchreplace', 'drafts', 'help' + ]] + //褰撻紶鏍囨斁鍦ㄥ伐鍏锋爮涓婃椂鏄剧ず鐨則ooltip鎻愮ず,鐣欑┖鏀寔鑷姩澶氳瑷�閰嶇疆锛屽惁鍒欎互閰嶇疆鍊间负鍑� + //,labelMap:{ + // 'anchor':'', 'undo':'' + //} + + //璇█閰嶇疆椤�,榛樿鏄痾h-cn銆傛湁闇�瑕佺殑璇濅篃鍙互浣跨敤濡備笅杩欐牱鐨勬柟寮忔潵鑷姩澶氳瑷�鍒囨崲锛屽綋鐒讹紝鍓嶆彁鏉′欢鏄痩ang鏂囦欢澶逛笅瀛樺湪瀵瑰簲鐨勮瑷�鏂囦欢锛� + //lang鍊间篃鍙互閫氳繃鑷姩鑾峰彇 (navigator.language||navigator.browserLanguage ||navigator.userLanguage).toLowerCase() + //,lang:"zh-cn" + //,langPath:URL +"lang/" + + //涓婚閰嶇疆椤�,榛樿鏄痙efault銆傛湁闇�瑕佺殑璇濅篃鍙互浣跨敤濡備笅杩欐牱鐨勬柟寮忔潵鑷姩澶氫富棰樺垏鎹紝褰撶劧锛屽墠鎻愭潯浠舵槸themes鏂囦欢澶逛笅瀛樺湪瀵瑰簲鐨勪富棰樻枃浠讹細 + //鐜版湁濡備笅鐨偆:default + //,theme:'default' + //,themePath:URL +"themes/" + + //,zIndex : 900 //缂栬緫鍣ㄥ眰绾х殑鍩烘暟,榛樿鏄�900 + + //閽堝getAllHtml鏂规硶锛屼細鍦ㄥ搴旂殑head鏍囩涓鍔犺缂栫爜璁剧疆銆� + //,charset:"utf-8" + + //鑻ュ疄渚嬪寲缂栬緫鍣ㄧ殑椤甸潰鎵嬪姩淇敼鐨刣omain锛屾澶勯渶瑕佽缃负true + //,customDomain:false + + //甯哥敤閰嶇疆椤圭洰 + //,isShow : true //榛樿鏄剧ず缂栬緫鍣� + + //,textarea:'editorValue' // 鎻愪氦琛ㄥ崟鏃讹紝鏈嶅姟鍣ㄨ幏鍙栫紪杈戝櫒鎻愪氦鍐呭鐨勬墍鐢ㄧ殑鍙傛暟锛屽瀹炰緥鏃跺彲浠ョ粰瀹瑰櫒name灞炴�э紝浼氬皢name缁欏畾鐨勫�兼渶涓烘瘡涓疄渚嬬殑閿�硷紝涓嶇敤姣忔瀹炰緥鍖栫殑鏃跺�欓兘璁剧疆杩欎釜鍊� + + //,initialContent:'娆㈣繋浣跨敤ueditor!' //鍒濆鍖栫紪杈戝櫒鐨勫唴瀹�,涔熷彲浠ラ�氳繃textarea/script缁欏�硷紝鐪嬪畼缃戜緥瀛� + + //,autoClearinitialContent:true //鏄惁鑷姩娓呴櫎缂栬緫鍣ㄥ垵濮嬪唴瀹癸紝娉ㄦ剰锛氬鏋渇ocus灞炴�ц缃负true,杩欎釜涔熶负鐪燂紝閭d箞缂栬緫鍣ㄤ竴涓婃潵灏变細瑙﹀彂瀵艰嚧鍒濆鍖栫殑鍐呭鐪嬩笉鍒颁簡 + + //,focus:false //鍒濆鍖栨椂锛屾槸鍚﹁缂栬緫鍣ㄨ幏寰楃劍鐐箃rue鎴杅alse + + //濡傛灉鑷畾涔夛紝鏈�濂界粰p鏍囩濡備笅鐨勮楂橈紝瑕佷笉杈撳叆涓枃鏃讹紝浼氭湁璺冲姩鎰� + //,initialStyle:'p{line-height:1em}'//缂栬緫鍣ㄥ眰绾х殑鍩烘暟,鍙互鐢ㄦ潵鏀瑰彉瀛椾綋绛� + + //,iframeCssUrl: URL + '/themes/iframe.css' //缁欑紪杈戝尯鍩熺殑iframe寮曞叆涓�涓猚ss鏂囦欢 + + //indentValue + //棣栬缂╄繘璺濈,榛樿鏄�2em + //,indentValue:'2em' + + //,initialFrameWidth:1000 //鍒濆鍖栫紪杈戝櫒瀹藉害,榛樿1000 + //,initialFrameHeight:320 //鍒濆鍖栫紪杈戝櫒楂樺害,榛樿320 + + //,readonly : false //缂栬緫鍣ㄥ垵濮嬪寲缁撴潫鍚�,缂栬緫鍖哄煙鏄惁鏄彧璇荤殑锛岄粯璁ゆ槸false + + //,autoClearEmptyNode : true //getContent鏃讹紝鏄惁鍒犻櫎绌虹殑inlineElement鑺傜偣锛堝寘鎷祵濂楃殑鎯呭喌锛� + + //鍚敤鑷姩淇濆瓨 + //,enableAutoSave: true + //鑷姩淇濆瓨闂撮殧鏃堕棿锛� 鍗曚綅ms + //,saveInterval: 500 + + //,fullscreen : false //鏄惁寮�鍚垵濮嬪寲鏃跺嵆鍏ㄥ睆锛岄粯璁ゅ叧闂� + + //,imagePopup:true //鍥剧墖鎿嶄綔鐨勬诞灞傚紑鍏筹紝榛樿鎵撳紑 + + //,autoSyncData:true //鑷姩鍚屾缂栬緫鍣ㄨ鎻愪氦鐨勬暟鎹� + //,emotionLocalization:false //鏄惁寮�鍚〃鎯呮湰鍦板寲锛岄粯璁ゅ叧闂�傝嫢瑕佸紑鍚纭繚emotion鏂囦欢澶逛笅鍖呭惈瀹樼綉鎻愪緵鐨刬mages琛ㄦ儏鏂囦欢澶� + + //绮樿创鍙繚鐣欐爣绛撅紝鍘婚櫎鏍囩鎵�鏈夊睘鎬� + //,retainOnlyLabelPasted: false + + //,pasteplain:false //鏄惁榛樿涓虹函鏂囨湰绮樿创銆俧alse涓轰笉浣跨敤绾枃鏈矘璐达紝true涓轰娇鐢ㄧ函鏂囨湰绮樿创 + //绾枃鏈矘璐存ā寮忎笅鐨勮繃婊よ鍒� + //'filterTxtRules' : function(){ + // function transP(node){ + // node.tagName = 'p'; + // node.setStyle(); + // } + // return { + // //鐩存帴鍒犻櫎鍙婂叾瀛楄妭鐐瑰唴瀹� + // '-' : 'script style object iframe embed input select', + // 'p': {$:{}}, + // 'br':{$:{}}, + // 'div':{'$':{}}, + // 'li':{'$':{}}, + // 'caption':transP, + // 'th':transP, + // 'tr':transP, + // 'h1':transP,'h2':transP,'h3':transP,'h4':transP,'h5':transP,'h6':transP, + // 'td':function(node){ + // //娌℃湁鍐呭鐨則d鐩存帴鍒犳帀 + // var txt = !!node.innerText(); + // if(txt){ + // node.parentNode.insertAfter(UE.uNode.createText(' '),node); + // } + // node.parentNode.removeChild(node,node.innerText()) + // } + // } + //}() + + //,allHtmlEnabled:false //鎻愪氦鍒板悗鍙扮殑鏁版嵁鏄惁鍖呭惈鏁翠釜html瀛楃涓� + + //insertorderedlist + //鏈夊簭鍒楄〃鐨勪笅鎷夐厤缃�,鍊肩暀绌烘椂鏀寔澶氳瑷�鑷姩璇嗗埆锛岃嫢閰嶇疆鍊硷紝鍒欎互姝ゅ�间负鍑� + //,'insertorderedlist':{ + // //鑷畾鐨勬牱寮� + // 'num':'1,2,3...', + // 'num1':'1),2),3)...', + // 'num2':'(1),(2),(3)...', + // 'cn':'涓�,浜�,涓�....', + // 'cn1':'涓�),浜�),涓�)....', + // 'cn2':'(涓�),(浜�),(涓�)....', + // //绯荤粺鑷甫 + // 'decimal' : '' , //'1,2,3...' + // 'lower-alpha' : '' , // 'a,b,c...' + // 'lower-roman' : '' , //'i,ii,iii...' + // 'upper-alpha' : '' , lang //'A,B,C' + // 'upper-roman' : '' //'I,II,III...' + //} + + //insertunorderedlist + //鏃犲簭鍒楄〃鐨勪笅鎷夐厤缃紝鍊肩暀绌烘椂鏀寔澶氳瑷�鑷姩璇嗗埆锛岃嫢閰嶇疆鍊硷紝鍒欎互姝ゅ�间负鍑� + //,insertunorderedlist : { //鑷畾鐨勬牱寮� + // 'dash' :'鈥� 鐮存姌鍙�', //-鐮存姌鍙� + // 'dot':' 銆� 灏忓渾鍦�', //绯荤粺鑷甫 + // 'circle' : '', // '鈼� 灏忓渾鍦�' + // 'disc' : '', // '鈼� 灏忓渾鐐�' + // 'square' : '' //'鈻� 灏忔柟鍧�' + //} + //,listDefaultPaddingLeft : '30'//榛樿鐨勫乏杈圭缉杩涚殑鍩烘暟鍊� + //,listiconpath : 'http://bs.baidu.com/listicon/'//鑷畾涔夋爣鍙风殑璺緞 + //,maxListLevel : 3 //闄愬埗鍙互tab鐨勭骇鏁�, 璁剧疆-1涓轰笉闄愬埗 + + //,autoTransWordToList:false //绂佹word涓矘璐磋繘鏉ョ殑鍒楄〃鑷姩鍙樻垚鍒楄〃鏍囩 + + //fontfamily + //瀛椾綋璁剧疆 label鐣欑┖鏀寔澶氳瑷�鑷姩鍒囨崲锛岃嫢閰嶇疆锛屽垯浠ラ厤缃�间负鍑� + //,'fontfamily':[ + // { label:'',name:'songti',val:'瀹嬩綋,SimSun'}, + // { label:'',name:'kaiti',val:'妤蜂綋,妤蜂綋_GB2312, SimKai'}, + // { label:'',name:'yahei',val:'寰蒋闆呴粦,Microsoft YaHei'}, + // { label:'',name:'heiti',val:'榛戜綋, SimHei'}, + // { label:'',name:'lishu',val:'闅朵功, SimLi'}, + // { label:'',name:'andaleMono',val:'andale mono'}, + // { label:'',name:'arial',val:'arial, helvetica,sans-serif'}, + // { label:'',name:'arialBlack',val:'arial black,avant garde'}, + // { label:'',name:'comicSansMs',val:'comic sans ms'}, + // { label:'',name:'impact',val:'impact,chicago'}, + // { label:'',name:'timesNewRoman',val:'times new roman'} + //] + + //fontsize + //瀛楀彿 + //,'fontsize':[10, 11, 12, 14, 16, 18, 20, 24, 36] + + //paragraph + //娈佃惤鏍煎紡 鍊肩暀绌烘椂鏀寔澶氳瑷�鑷姩璇嗗埆锛岃嫢閰嶇疆锛屽垯浠ラ厤缃�间负鍑� + //,'paragraph':{'p':'', 'h1':'', 'h2':'', 'h3':'', 'h4':'', 'h5':'', 'h6':''} + + //rowspacingtop + //娈甸棿璺� 鍊煎拰鏄剧ず鐨勫悕瀛楃浉鍚� + //,'rowspacingtop':['5', '10', '15', '20', '25'] + + //rowspacingBottom + //娈甸棿璺� 鍊煎拰鏄剧ず鐨勫悕瀛楃浉鍚� + //,'rowspacingbottom':['5', '10', '15', '20', '25'] + + //lineheight + //琛屽唴闂磋窛 鍊煎拰鏄剧ず鐨勫悕瀛楃浉鍚� + //,'lineheight':['1', '1.5','1.75','2', '3', '4', '5'] + + //customstyle + //鑷畾涔夋牱寮忥紝涓嶆敮鎸佸浗闄呭寲锛屾澶勯厤缃�煎嵆鍙渶鍚庢樉绀哄�� + //block鐨勫厓绱犳槸渚濇嵁璁剧疆娈佃惤鐨勯�昏緫璁剧疆鐨勶紝inline鐨勫厓绱犱緷鎹瓸IU鐨勯�昏緫璁剧疆 + //灏介噺浣跨敤涓�浜涘父鐢ㄧ殑鏍囩 + //鍙傛暟璇存槑 + //tag 浣跨敤鐨勬爣绛惧悕瀛� + //label 鏄剧ず鐨勫悕瀛椾篃鏄敤鏉ユ爣璇嗕笉鍚岀被鍨嬬殑鏍囪瘑绗︼紝娉ㄦ剰杩欎釜鍊兼瘡涓涓嶅悓锛� + //style 娣诲姞鐨勬牱寮� + //姣忎竴涓璞″氨鏄竴涓嚜瀹氫箟鐨勬牱寮� + //,'customstyle':[ + // {tag:'h1', name:'tc', label:'', style:'border-bottom:#ccc 2px solid;padding:0 4px 0 0;text-align:center;margin:0 0 20px 0;'}, + // {tag:'h1', name:'tl',label:'', style:'border-bottom:#ccc 2px solid;padding:0 4px 0 0;margin:0 0 10px 0;'}, + // {tag:'span',name:'im', label:'', style:'font-style:italic;font-weight:bold'}, + // {tag:'span',name:'hi', label:'', style:'font-style:italic;font-weight:bold;color:rgb(51, 153, 204)'} + //] + + //鎵撳紑鍙抽敭鑿滃崟鍔熻兘 + //,enableContextMenu: true + //鍙抽敭鑿滃崟鐨勫唴瀹癸紝鍙互鍙傝�僷lugins/contextmenu.js閲岃竟鐨勯粯璁よ彍鍗曠殑渚嬪瓙锛宭abel鐣欑┖鏀寔鍥介檯鍖栵紝鍚﹀垯浠ユ閰嶇疆涓哄噯 + //,contextMenu:[ + // { + // label:'', //鏄剧ず鐨勫悕绉� + // cmdName:'selectall',//鎵ц鐨刢ommand鍛戒护锛屽綋鐐瑰嚮杩欎釜鍙抽敭鑿滃崟鏃� + // //exec鍙�夛紝鏈変簡exec灏变細鍦ㄧ偣鍑绘椂鎵ц杩欎釜function锛屼紭鍏堢骇楂樹簬cmdName + // exec:function () { + // //this鏄綋鍓嶇紪杈戝櫒鐨勫疄渚� + // //this.ui._dialogs['inserttableDialog'].open(); + // } + // } + //] + + //蹇嵎鑿滃崟 + //,shortcutMenu:["fontfamily", "fontsize", "bold", "italic", "underline", "forecolor", "backcolor", "insertorderedlist", "insertunorderedlist"] + + //elementPathEnabled + //鏄惁鍚敤鍏冪礌璺緞锛岄粯璁ゆ槸鏄剧ず + //,elementPathEnabled : true + + //wordCount + //,wordCount:true //鏄惁寮�鍚瓧鏁扮粺璁� + //,maximumWords:10000 //鍏佽鐨勬渶澶у瓧绗︽暟 + //瀛楁暟缁熻鎻愮ず锛寋#count}浠h〃褰撳墠瀛楁暟锛寋#leave}浠h〃杩樺彲浠ヨ緭鍏ュ灏戝瓧绗︽暟,鐣欑┖鏀寔澶氳瑷�鑷姩鍒囨崲锛屽惁鍒欐寜姝ら厤缃樉绀� + //,wordCountMsg:'' //褰撳墠宸茶緭鍏� {#count} 涓瓧绗︼紝鎮ㄨ繕鍙互杈撳叆{#leave} 涓瓧绗� + //瓒呭嚭瀛楁暟闄愬埗鎻愮ず 鐣欑┖鏀寔澶氳瑷�鑷姩鍒囨崲锛屽惁鍒欐寜姝ら厤缃樉绀� + //,wordOverFlowMsg:'' //<span style="color:red;">浣犺緭鍏ョ殑瀛楃涓暟宸茬粡瓒呭嚭鏈�澶у厑璁稿�硷紝鏈嶅姟鍣ㄥ彲鑳戒細鎷掔粷淇濆瓨锛�</span> + + //tab + //鐐瑰嚮tab閿椂绉诲姩鐨勮窛绂�,tabSize鍊嶆暟锛宼abNode浠�涔堝瓧绗﹀仛涓哄崟浣� + //,tabSize:4 + //,tabNode:' ' + + //removeFormat + //娓呴櫎鏍煎紡鏃跺彲浠ュ垹闄ょ殑鏍囩鍜屽睘鎬� + //removeForamtTags鏍囩 + //,removeFormatTags:'b,big,code,del,dfn,em,font,i,ins,kbd,q,samp,small,span,strike,strong,sub,sup,tt,u,var' + //removeFormatAttributes灞炴�� + //,removeFormatAttributes:'class,style,lang,width,height,align,hspace,valign' + + //undo + //鍙互鏈�澶氬洖閫�鐨勬鏁�,榛樿20 + //,maxUndoCount:20 + //褰撹緭鍏ョ殑瀛楃鏁拌秴杩囪鍊兼椂锛屼繚瀛樹竴娆$幇鍦� + //,maxInputCount:1 + + //autoHeightEnabled + // 鏄惁鑷姩闀块珮,榛樿true + //,autoHeightEnabled:true + + //scaleEnabled + //鏄惁鍙互鎷変几闀块珮,榛樿true(褰撳紑鍚椂锛岃嚜鍔ㄩ暱楂樺け鏁�) + //,scaleEnabled:false + //,minFrameWidth:800 //缂栬緫鍣ㄦ嫋鍔ㄦ椂鏈�灏忓搴�,榛樿800 + //,minFrameHeight:220 //缂栬緫鍣ㄦ嫋鍔ㄦ椂鏈�灏忛珮搴�,榛樿220 + + //autoFloatEnabled + //鏄惁淇濇寔toolbar鐨勪綅缃笉鍔�,榛樿true + //,autoFloatEnabled:true + //娴姩鏃跺伐鍏锋爮璺濈娴忚鍣ㄩ《閮ㄧ殑楂樺害锛岀敤浜庢煇浜涘叿鏈夊浐瀹氬ご閮ㄧ殑椤甸潰 + //,topOffset:30 + //缂栬緫鍣ㄥ簳閮ㄨ窛绂诲伐鍏锋爮楂樺害(濡傛灉鍙傛暟澶т簬绛変簬缂栬緫鍣ㄩ珮搴︼紝鍒欒缃棤鏁�) + //,toolbarTopOffset:400 + + //璁剧疆杩滅▼鍥剧墖鏄惁鎶撳彇鍒版湰鍦颁繚瀛� + //,catchRemoteImageEnable: true //璁剧疆鏄惁鎶撳彇杩滅▼鍥剧墖 + + //pageBreakTag + //鍒嗛〉鏍囪瘑绗�,榛樿鏄痏ueditor_page_break_tag_ + //,pageBreakTag:'_ueditor_page_break_tag_' + + //autotypeset + //鑷姩鎺掔増鍙傛暟 + //,autotypeset: { + // mergeEmptyline: true, //鍚堝苟绌鸿 + // removeClass: true, //鍘绘帀鍐椾綑鐨刢lass + // removeEmptyline: false, //鍘绘帀绌鸿 + // textAlign:"left", //娈佃惤鐨勬帓鐗堟柟寮忥紝鍙互鏄� left,right,center,justify 鍘绘帀杩欎釜灞炴�ц〃绀轰笉鎵ц鎺掔増 + // imageBlockLine: 'center', //鍥剧墖鐨勬诞鍔ㄦ柟寮忥紝鐙崰涓�琛屽墽涓�,宸﹀彸娴姩锛岄粯璁�: center,left,right,none 鍘绘帀杩欎釜灞炴�ц〃绀轰笉鎵ц鎺掔増 + // pasteFilter: false, //鏍规嵁瑙勫垯杩囨护娌′簨绮樿创杩涙潵鐨勫唴瀹� + // clearFontSize: false, //鍘绘帀鎵�鏈夌殑鍐呭祵瀛楀彿锛屼娇鐢ㄧ紪杈戝櫒榛樿鐨勫瓧鍙� + // clearFontFamily: false, //鍘绘帀鎵�鏈夌殑鍐呭祵瀛椾綋锛屼娇鐢ㄧ紪杈戝櫒榛樿鐨勫瓧浣� + // removeEmptyNode: false, // 鍘绘帀绌鸿妭鐐� + // //鍙互鍘绘帀鐨勬爣绛� + // removeTagNames: {鏍囩鍚嶅瓧:1}, + // indent: false, // 琛岄缂╄繘 + // indentValue : '2em', //琛岄缂╄繘鐨勫ぇ灏� + // bdc2sb: false, + // tobdc: false + //} + + //tableDragable + //琛ㄦ牸鏄惁鍙互鎷栨嫿 + //,tableDragable: true + + + + //sourceEditor + //婧愮爜鐨勬煡鐪嬫柟寮�,codemirror 鏄唬鐮侀珮浜紝textarea鏄枃鏈,榛樿鏄痗odemirror + //娉ㄦ剰榛樿codemirror鍙兘鍦╥e8+鍜岄潪ie涓娇鐢� + //,sourceEditor:"codemirror" + //濡傛灉sourceEditor鏄痗odemirror锛岃繕鐢ㄩ厤缃竴涓嬩袱涓弬鏁� + //codeMirrorJsUrl js鍔犺浇鐨勮矾寰勶紝榛樿鏄� URL + "third-party/codemirror/codemirror.js" + //,codeMirrorJsUrl:URL + "third-party/codemirror/codemirror.js" + //codeMirrorCssUrl css鍔犺浇鐨勮矾寰勶紝榛樿鏄� URL + "third-party/codemirror/codemirror.css" + //,codeMirrorCssUrl:URL + "third-party/codemirror/codemirror.css" + //缂栬緫鍣ㄥ垵濮嬪寲瀹屾垚鍚庢槸鍚﹁繘鍏ユ簮鐮佹ā寮忥紝榛樿涓哄惁銆� + //,sourceEditorFirst:false + + //iframeUrlMap + //dialog鍐呭鐨勮矾寰� 锝炰細琚浛鎹㈡垚URL,鍨撳睘鎬т竴鏃︽墦寮�锛屽皢瑕嗙洊鎵�鏈夌殑dialog鐨勯粯璁よ矾寰� + //,iframeUrlMap:{ + // 'anchor':'~/dialogs/anchor/anchor.html', + //} + + //allowLinkProtocol 鍏佽鐨勯摼鎺ュ湴鍧�锛屾湁杩欎簺鍓嶇紑鐨勯摼鎺ュ湴鍧�涓嶄細鑷姩娣诲姞http + //, allowLinkProtocols: ['http:', 'https:', '#', '/', 'ftp:', 'mailto:', 'tel:', 'git:', 'svn:'] + + //webAppKey 鐧惧害搴旂敤鐨凙PIkey锛屾瘡涓珯闀垮繀椤婚鍏堝幓鐧惧害瀹樼綉娉ㄥ唽涓�涓猭ey鍚庢柟鑳芥甯镐娇鐢╝pp鍔熻兘锛屾敞鍐屼粙缁嶏紝http://app.baidu.com/static/cms/getapikey.html + //, webAppKey: "" + + //榛樿杩囨护瑙勫垯鐩稿叧閰嶇疆椤圭洰 + //,disabledTableInTable:true //绂佹琛ㄦ牸宓屽 + //,allowDivTransToP:true //鍏佽杩涘叆缂栬緫鍣ㄧ殑div鏍囩鑷姩鍙樻垚p鏍囩 + //,rgb2Hex:true //榛樿浜у嚭鐨勬暟鎹腑鐨刢olor鑷姩浠巖gb鏍煎紡鍙樻垚16杩涘埗鏍煎紡 + + // xss 杩囨护鏄惁寮�鍚�,inserthtml绛夋搷浣� + ,xssFilterRules: true + //input xss杩囨护 + ,inputXssFilter: true + //output xss杩囨护 + ,outputXssFilter: true + // xss杩囨护鐧藉悕鍗� 鍚嶅崟鏉ユ簮: https://raw.githubusercontent.com/leizongmin/js-xss/master/lib/default.js + ,whitList: { + a: ['target', 'href', 'title', 'class', 'style'], + abbr: ['title', 'class', 'style'], + address: ['class', 'style'], + area: ['shape', 'coords', 'href', 'alt'], + article: [], + aside: [], + audio: ['autoplay', 'controls', 'loop', 'preload', 'src', 'class', 'style'], + b: ['class', 'style'], + bdi: ['dir'], + bdo: ['dir'], + big: [], + blockquote: ['cite', 'class', 'style'], + br: [], + caption: ['class', 'style'], + center: [], + cite: [], + code: ['class', 'style'], + col: ['align', 'valign', 'span', 'width', 'class', 'style'], + colgroup: ['align', 'valign', 'span', 'width', 'class', 'style'], + dd: ['class', 'style'], + del: ['datetime'], + details: ['open'], + div: ['class', 'style'], + dl: ['class', 'style'], + dt: ['class', 'style'], + em: ['class', 'style'], + font: ['color', 'size', 'face'], + footer: [], + h1: ['class', 'style'], + h2: ['class', 'style'], + h3: ['class', 'style'], + h4: ['class', 'style'], + h5: ['class', 'style'], + h6: ['class', 'style'], + header: [], + hr: [], + i: ['class', 'style'], + img: ['src', 'alt', 'title', 'width', 'height', 'id', '_src', 'loadingclass', 'class', 'data-latex'], + ins: ['datetime'], + li: ['class', 'style'], + mark: [], + nav: [], + ol: ['class', 'style'], + p: ['class', 'style'], + pre: ['class', 'style'], + s: [], + section:[], + small: [], + span: ['class', 'style'], + sub: ['class', 'style'], + sup: ['class', 'style'], + strong: ['class', 'style'], + table: ['width', 'border', 'align', 'valign', 'class', 'style'], + tbody: ['align', 'valign', 'class', 'style'], + td: ['width', 'rowspan', 'colspan', 'align', 'valign', 'class', 'style'], + tfoot: ['align', 'valign', 'class', 'style'], + th: ['width', 'rowspan', 'colspan', 'align', 'valign', 'class', 'style'], + thead: ['align', 'valign', 'class', 'style'], + tr: ['rowspan', 'align', 'valign', 'class', 'style'], + tt: [], + u: [], + ul: ['class', 'style'], + video: ['autoplay', 'controls', 'loop', 'preload', 'src', 'height', 'width', 'class', 'style'] + } + }; + + function getUEBasePath(docUrl, confUrl) { + + return getBasePath(docUrl || self.document.URL || self.location.href, confUrl || getConfigFilePath()); + + } + + function getConfigFilePath() { + + var configPath = document.getElementsByTagName('script'); + + return configPath[ configPath.length - 1 ].src; + + } + + function getBasePath(docUrl, confUrl) { + + var basePath = confUrl; + + + if (/^(\/|\\\\)/.test(confUrl)) { + + basePath = /^.+?\w(\/|\\\\)/.exec(docUrl)[0] + confUrl.replace(/^(\/|\\\\)/, ''); + + } else if (!/^[a-z]+:/i.test(confUrl)) { + + docUrl = docUrl.split("#")[0].split("?")[0].replace(/[^\\\/]+$/, ''); + + basePath = docUrl + "" + confUrl; + + } + + return optimizationPath(basePath); + + } + + function optimizationPath(path) { + + var protocol = /^[a-z]+:\/\//.exec(path)[ 0 ], + tmp = null, + res = []; + + path = path.replace(protocol, "").split("?")[0].split("#")[0]; + + path = path.replace(/\\/g, '/').split(/\//); + + path[ path.length - 1 ] = ""; + + while (path.length) { + + if (( tmp = path.shift() ) === "..") { + res.pop(); + } else if (tmp !== ".") { + res.push(tmp); + } + + } + + return protocol + res.join("/"); + + } + + window.UE = { + getUEBasePath: getUEBasePath + }; + +})(); -- Gitblit v1.8.0