diff --git a/view/admin/approval_details.html b/view/admin/approval_details.html
index 8e8dd4319..2051d708e 100644
--- a/view/admin/approval_details.html
+++ b/view/admin/approval_details.html
@@ -19,7 +19,7 @@
{{controller.meta_title}}
{{k}} |
- {{v|safe}} |
+ {% if k =='content'%}{{v|safe}}{%else%}{{v}}{%endif%} |
{%endfor%}
diff --git a/view/admin/approval_index.html b/view/admin/approval_index.html
index 0a717f242..1952d53b2 100644
--- a/view/admin/approval_index.html
+++ b/view/admin/approval_index.html
@@ -50,12 +50,12 @@
|
{{item.uid|get_nickname}} |
- {{item.title|delhtmltags}} |
+ {{item.title}} |
{{item.time | moment('YYYY-MM-DD HH:mm:ss')}} |
-
+
diff --git a/view/center/publish_approvaldetails.html b/view/center/publish_approvaldetails.html
index 6681192ff..ce06e2569 100644
--- a/view/center/publish_approvaldetails.html
+++ b/view/center/publish_approvaldetails.html
@@ -19,7 +19,7 @@ {{controller.meta_title}}
|
{{k}} |
- {{v|safe}} |
+ {% if k =='content'%}{{v|safe}}{%else%}{{v}}{%endif%} |
{%endfor%}
diff --git a/www/static/admin/js/udeitor/third-party/SyntaxHighlighter/shCoreDefault.css b/www/static/admin/js/udeitor/third-party/SyntaxHighlighter/shCoreDefault.css
index f126e989e..e156a6f43 100644
--- a/www/static/admin/js/udeitor/third-party/SyntaxHighlighter/shCoreDefault.css
+++ b/www/static/admin/js/udeitor/third-party/SyntaxHighlighter/shCoreDefault.css
@@ -1,365 +1 @@
-.syntaxhighlighter a, .syntaxhighlighter div, .syntaxhighlighter code, .syntaxhighlighter, .syntaxhighlighter td, .syntaxhighlighter tr, .syntaxhighlighter tbody, .syntaxhighlighter thead, .syntaxhighlighter caption, .syntaxhighlighter textarea {
- -moz-border-radius: 0 0 0 0 !important;
- -webkit-border-radius: 0 0 0 0 !important;
- background: none !important;
- border: 0 !important;
- bottom: auto !important;
- float: none !important;
- left: auto !important;
- line-height: 1.1em !important;
- margin: 0 !important;
- outline: 0 !important;
- overflow: visible !important;
- padding: 0 !important;
- position: static !important;
- right: auto !important;
- text-align: left !important;
- top: auto !important;
- vertical-align: baseline !important;
- width: auto !important;
- box-sizing: content-box !important;
- font-family: Consolas, Monaco, monospace;;
- font-weight: normal !important;
- font-style: normal !important;
- min-height: inherit !important;
- min-height: auto !important;
- font-size: 14px !important
-}
-
-.syntaxhighlighter {
- width: 100% !important;
- margin: .3em 0 .3em 0 !important;
- position: relative !important;
- overflow: auto !important;
- background-color: #f5f5f5 !important;
- border: 1px solid #ccc !important;
- border-radius: 4px !important;
- border-collapse: separate !important
-}
-
-.syntaxhighlighter.source {
- overflow: hidden !important
-}
-
-.syntaxhighlighter .bold {
- font-weight: bold !important
-}
-
-.syntaxhighlighter .italic {
- font-style: italic !important
-}
-
-.syntaxhighlighter .gutter div {
- white-space: pre !important;
- word-wrap: normal
-}
-
-.syntaxhighlighter caption {
- text-align: left !important;
- padding: .5em 0 .5em 1em !important
-}
-
-.syntaxhighlighter td.code {
- width: 100% !important
-}
-
-.syntaxhighlighter td.code .container {
- position: relative !important;
-}
-.syntaxhighlighter td.code .container:before{
- display: none !important;
- content: none !important;
-}
-
-.syntaxhighlighter td.code .container textarea {
- box-sizing: border-box !important;
- position: absolute !important;
- left: 0 !important;
- top: 0 !important;
- width: 100% !important;
- border: none !important;
- background: white !important;
- padding-left: 1em !important;
- overflow: hidden !important;
- white-space: pre !important
-}
-
-.syntaxhighlighter td.gutter .line {
- text-align: right !important;
- padding: 0 .5em 0 1em !important
-}
-
-.syntaxhighlighter td.code .line {
- padding: 0 1em !important
-}
-
-.syntaxhighlighter.nogutter td.code .container textarea, .syntaxhighlighter.nogutter td.code .line {
- padding-left: 0 !important;
-}
-
-.syntaxhighlighter.show {
- display: block !important
-}
-
-.syntaxhighlighter.collapsed table {
- display: none !important
-}
-
-.syntaxhighlighter.collapsed .toolbar {
- padding: .1em .8em 0 .8em !important;
- font-size: 1em !important;
- position: static !important;
- width: auto !important
-}
-
-.syntaxhighlighter.collapsed .toolbar span {
- display: inline !important;
- margin-right: 1em !important
-}
-
-.syntaxhighlighter.collapsed .toolbar span a {
- padding: 0 !important;
- display: none !important
-}
-
-.syntaxhighlighter.collapsed .toolbar span a.expandSource {
- display: inline !important
-}
-
-.syntaxhighlighter .toolbar {
- position: absolute !important;
- right: 1px !important;
- top: 1px !important;
- width: 11px !important;
- height: 11px !important;
- font-size: 10px !important;
- z-index: 10 !important
-}
-
-.syntaxhighlighter .toolbar span.title {
- display: inline !important
-}
-
-.syntaxhighlighter .toolbar a {
- display: block !important;
- text-align: center !important;
- text-decoration: none !important;
- padding-top: 1px !important
-}
-
-.syntaxhighlighter .toolbar a.expandSource {
- display: none !important
-}
-
-.syntaxhighlighter.ie {
- font-size: .9em !important;
- padding: 1px 0 1px 0 !important
-}
-
-.syntaxhighlighter.ie .toolbar {
- line-height: 8px !important
-}
-
-.syntaxhighlighter.ie .toolbar a {
- padding-top: 0 !important
-}
-
-.syntaxhighlighter.printing .line.alt1 .content, .syntaxhighlighter.printing .line.alt2 .content, .syntaxhighlighter.printing .line.highlighted .number, .syntaxhighlighter.printing .line.highlighted.alt1 .content, .syntaxhighlighter.printing .line.highlighted.alt2 .content {
- background: none !important
-}
-
-.syntaxhighlighter.printing .line .number {
- color: #bbb !important
-}
-
-.syntaxhighlighter.printing .line .content {
- color: black !important
-}
-
-.syntaxhighlighter.printing .toolbar {
- display: none !important
-}
-
-.syntaxhighlighter.printing a {
- text-decoration: none !important
-}
-
-.syntaxhighlighter.printing .plain, .syntaxhighlighter.printing .plain a {
- color: black !important
-}
-
-.syntaxhighlighter.printing .comments, .syntaxhighlighter.printing .comments a {
- color: #008200 !important
-}
-
-.syntaxhighlighter.printing .string, .syntaxhighlighter.printing .string a {
- color: blue !important
-}
-
-.syntaxhighlighter.printing .keyword {
- color: #ff7800 !important;
- font-weight: bold !important
-}
-
-.syntaxhighlighter.printing .preprocessor {
- color: gray !important
-}
-
-.syntaxhighlighter.printing .variable {
- color: #a70 !important
-}
-
-.syntaxhighlighter.printing .value {
- color: #090 !important
-}
-
-.syntaxhighlighter.printing .functions {
- color: #ff1493 !important
-}
-
-.syntaxhighlighter.printing .constants {
- color: #06c !important
-}
-
-.syntaxhighlighter.printing .script {
- font-weight: bold !important
-}
-
-.syntaxhighlighter.printing .color1, .syntaxhighlighter.printing .color1 a {
- color: gray !important
-}
-
-.syntaxhighlighter.printing .color2, .syntaxhighlighter.printing .color2 a {
- color: #ff1493 !important
-}
-
-.syntaxhighlighter.printing .color3, .syntaxhighlighter.printing .color3 a {
- color: red !important
-}
-
-.syntaxhighlighter.printing .break, .syntaxhighlighter.printing .break a {
- color: black !important
-}
-
-.syntaxhighlighter {
- background-color: #f5f5f5 !important
-}
-
-.syntaxhighlighter .line.highlighted.number {
- color: black !important
-}
-
-.syntaxhighlighter caption {
- color: black !important
-}
-
-.syntaxhighlighter .gutter {
- color: #afafaf !important;
- background-color: #f7f7f9 !important;
- border-right: 1px solid #e1e1e8 !important;
- padding: 9.5px 0 9.5px 9.5px !important;
- border-top-left-radius: 4px !important;
- border-bottom-left-radius: 4px !important;
- user-select: none !important;
- -moz-user-select: none !important;
- -webkit-user-select: none !important
-}
-
-.syntaxhighlighter .gutter .line.highlighted {
- background-color: #6ce26c !important;
- color: white !important
-}
-
-.syntaxhighlighter.printing .line .content {
- border: none !important
-}
-
-.syntaxhighlighter.collapsed {
- overflow: visible !important
-}
-
-.syntaxhighlighter.collapsed .toolbar {
- color: blue !important;
- background: white !important;
- border: 1px solid #6ce26c !important
-}
-
-.syntaxhighlighter.collapsed .toolbar a {
- color: blue !important
-}
-
-.syntaxhighlighter.collapsed .toolbar a:hover {
- color: red !important
-}
-
-.syntaxhighlighter .toolbar {
- color: white !important;
- background: #6ce26c !important;
- border: none !important
-}
-
-.syntaxhighlighter .toolbar a {
- color: white !important
-}
-
-.syntaxhighlighter .toolbar a:hover {
- color: black !important
-}
-
-.syntaxhighlighter .plain, .syntaxhighlighter .plain a {
- color: black !important
-}
-
-.syntaxhighlighter .comments, .syntaxhighlighter .comments a {
- color: #008200 !important
-}
-
-.syntaxhighlighter .string, .syntaxhighlighter .string a {
- color: blue !important
-}
-
-.syntaxhighlighter .keyword {
- color: #ff7800 !important
-}
-
-.syntaxhighlighter .preprocessor {
- color: gray !important
-}
-
-.syntaxhighlighter .variable {
- color: #a70 !important
-}
-
-.syntaxhighlighter .value {
- color: #090 !important
-}
-
-.syntaxhighlighter .functions {
- color: #ff1493 !important
-}
-
-.syntaxhighlighter .constants {
- color: #06c !important
-}
-
-.syntaxhighlighter .script {
- font-weight: bold !important;
- color: #ff7800 !important;
- background-color: none !important
-}
-
-.syntaxhighlighter .color1, .syntaxhighlighter .color1 a {
- color: gray !important
-}
-
-.syntaxhighlighter .color2, .syntaxhighlighter .color2 a {
- color: #ff1493 !important
-}
-
-.syntaxhighlighter .color3, .syntaxhighlighter .color3 a {
- color: red !important
-}
-
-.syntaxhighlighter .keyword {
- font-weight: bold !important
-}
\ No newline at end of file
+.syntaxhighlighter a,.syntaxhighlighter div,.syntaxhighlighter code,.syntaxhighlighter,.syntaxhighlighter td,.syntaxhighlighter tr,.syntaxhighlighter tbody,.syntaxhighlighter thead,.syntaxhighlighter caption,.syntaxhighlighter textarea{-moz-border-radius:0 0 0 0!important;-webkit-border-radius:0 0 0 0!important;background:none!important;border:0!important;bottom:auto!important;float:none!important;left:auto!important;line-height:1.1em!important;margin:0!important;outline:0!important;overflow:visible!important;padding:0!important;position:static!important;right:auto!important;text-align:left!important;top:auto!important;vertical-align:baseline!important;width:auto!important;box-sizing:content-box!important;font-family:Monaco,Menlo,Consolas,"Courier New",monospace;font-weight:normal!important;font-style:normal!important;min-height:inherit!important;min-height:auto!important;font-size:13px!important}.syntaxhighlighter{width:100%!important;margin:.3em 0 .3em 0!important;position:relative!important;overflow:auto!important;background-color:#f5f5f5!important;border:1px solid #ccc!important;border-radius:4px!important;border-collapse:separate!important}.syntaxhighlighter.source{overflow:hidden!important}.syntaxhighlighter .bold{font-weight:bold!important}.syntaxhighlighter .italic{font-style:italic!important}.syntaxhighlighter .gutter div{white-space:pre!important;word-wrap:normal}.syntaxhighlighter caption{text-align:left!important;padding:.5em 0 .5em 1em!important}.syntaxhighlighter td.code{width:100%!important}.syntaxhighlighter td.code .container{position:relative!important}.syntaxhighlighter td.code .container textarea{box-sizing:border-box!important;position:absolute!important;left:0!important;top:0!important;width:100%!important;border:none!important;background:white!important;padding-left:1em!important;overflow:hidden!important;white-space:pre!important}.syntaxhighlighter td.gutter .line{text-align:right!important;padding:0 .5em 0 1em!important}.syntaxhighlighter td.code .line{padding:0 1em!important}.syntaxhighlighter.nogutter td.code .container textarea,.syntaxhighlighter.nogutter td.code .line{padding-left:0!important}.syntaxhighlighter.show{display:block!important}.syntaxhighlighter.collapsed table{display:none!important}.syntaxhighlighter.collapsed .toolbar{padding:.1em .8em 0 .8em!important;font-size:1em!important;position:static!important;width:auto!important}.syntaxhighlighter.collapsed .toolbar span{display:inline!important;margin-right:1em!important}.syntaxhighlighter.collapsed .toolbar span a{padding:0!important;display:none!important}.syntaxhighlighter.collapsed .toolbar span a.expandSource{display:inline!important}.syntaxhighlighter .toolbar{position:absolute!important;right:1px!important;top:1px!important;width:11px!important;height:11px!important;font-size:10px!important;z-index:10!important}.syntaxhighlighter .toolbar span.title{display:inline!important}.syntaxhighlighter .toolbar a{display:block!important;text-align:center!important;text-decoration:none!important;padding-top:1px!important}.syntaxhighlighter .toolbar a.expandSource{display:none!important}.syntaxhighlighter.ie{font-size:.9em!important;padding:1px 0 1px 0!important}.syntaxhighlighter.ie .toolbar{line-height:8px!important}.syntaxhighlighter.ie .toolbar a{padding-top:0!important}.syntaxhighlighter.printing .line.alt1 .content,.syntaxhighlighter.printing .line.alt2 .content,.syntaxhighlighter.printing .line.highlighted .number,.syntaxhighlighter.printing .line.highlighted.alt1 .content,.syntaxhighlighter.printing .line.highlighted.alt2 .content{background:none!important}.syntaxhighlighter.printing .line .number{color:#bbb!important}.syntaxhighlighter.printing .line .content{color:black!important}.syntaxhighlighter.printing .toolbar{display:none!important}.syntaxhighlighter.printing a{text-decoration:none!important}.syntaxhighlighter.printing .plain,.syntaxhighlighter.printing .plain a{color:black!important}.syntaxhighlighter.printing .comments,.syntaxhighlighter.printing .comments a{color:#008200!important}.syntaxhighlighter.printing .string,.syntaxhighlighter.printing .string a{color:blue!important}.syntaxhighlighter.printing .keyword{color:#ff7800!important;font-weight:bold!important}.syntaxhighlighter.printing .preprocessor{color:gray!important}.syntaxhighlighter.printing .variable{color:#a70!important}.syntaxhighlighter.printing .value{color:#090!important}.syntaxhighlighter.printing .functions{color:#ff1493!important}.syntaxhighlighter.printing .constants{color:#06c!important}.syntaxhighlighter.printing .script{font-weight:bold!important}.syntaxhighlighter.printing .color1,.syntaxhighlighter.printing .color1 a{color:gray!important}.syntaxhighlighter.printing .color2,.syntaxhighlighter.printing .color2 a{color:#ff1493!important}.syntaxhighlighter.printing .color3,.syntaxhighlighter.printing .color3 a{color:red!important}.syntaxhighlighter.printing .break,.syntaxhighlighter.printing .break a{color:black!important}.syntaxhighlighter{background-color:#f5f5f5!important}.syntaxhighlighter .line.highlighted.number{color:black!important}.syntaxhighlighter caption{color:black!important}.syntaxhighlighter .gutter{color:#afafaf!important;background-color:#f7f7f9!important;border-right:1px solid #e1e1e8!important;padding:9.5px 0 9.5px 9.5px!important;border-top-left-radius:4px!important;border-bottom-left-radius:4px!important;user-select:none!important;-moz-user-select:none!important;-webkit-user-select:none!important}.syntaxhighlighter .gutter .line.highlighted{background-color:#6ce26c!important;color:white!important}.syntaxhighlighter.printing .line .content{border:none!important}.syntaxhighlighter.collapsed{overflow:visible!important}.syntaxhighlighter.collapsed .toolbar{color:blue!important;background:white!important;border:1px solid #6ce26c!important}.syntaxhighlighter.collapsed .toolbar a{color:blue!important}.syntaxhighlighter.collapsed .toolbar a:hover{color:red!important}.syntaxhighlighter .toolbar{color:white!important;background:#6ce26c!important;border:none!important}.syntaxhighlighter .toolbar a{color:white!important}.syntaxhighlighter .toolbar a:hover{color:black!important}.syntaxhighlighter .plain,.syntaxhighlighter .plain a{color:black!important}.syntaxhighlighter .comments,.syntaxhighlighter .comments a{color:#008200!important}.syntaxhighlighter .string,.syntaxhighlighter .string a{color:blue!important}.syntaxhighlighter .keyword{color:#ff7800!important}.syntaxhighlighter .preprocessor{color:gray!important}.syntaxhighlighter .variable{color:#a70!important}.syntaxhighlighter .value{color:#090!important}.syntaxhighlighter .functions{color:#ff1493!important}.syntaxhighlighter .constants{color:#06c!important}.syntaxhighlighter .script{font-weight:bold!important;color:#ff7800!important;background-color:none!important}.syntaxhighlighter .color1,.syntaxhighlighter .color1 a{color:gray!important}.syntaxhighlighter .color2,.syntaxhighlighter .color2 a{color:#ff1493!important}.syntaxhighlighter .color3,.syntaxhighlighter .color3 a{color:red!important}.syntaxhighlighter .keyword{font-weight:bold!important}
\ No newline at end of file
diff --git a/www/static/admin/js/udeitor/third-party/highcharts/highcharts.src.js b/www/static/admin/js/udeitor/third-party/highcharts/highcharts.src.js
index 649bfb084..a29b0fad1 100644
--- a/www/static/admin/js/udeitor/third-party/highcharts/highcharts.src.js
+++ b/www/static/admin/js/udeitor/third-party/highcharts/highcharts.src.js
@@ -4495,7 +4495,7 @@ SVGRenderer.prototype = {
return wrapper;
},
/**
- * Destroy and wangEditor memory.
+ * Destroy and release memory.
*/
destroy: function () {
removeEvent(wrapper, 'add', getSizeAfterAdd);
diff --git a/www/static/admin/js/udeitor/third-party/jquery-1.10.2.js b/www/static/admin/js/udeitor/third-party/jquery-1.10.2.js
index 23f763da8..c5c648255 100644
--- a/www/static/admin/js/udeitor/third-party/jquery-1.10.2.js
+++ b/www/static/admin/js/udeitor/third-party/jquery-1.10.2.js
@@ -399,7 +399,7 @@ jQuery.extend({
// the ready event fires. See #6781
readyWait: 1,
- // Hold (or wangEditor) the ready event
+ // Hold (or release) the ready event
holdReady: function( hold ) {
if ( hold ) {
jQuery.readyWait++;
@@ -1334,7 +1334,7 @@ function assert( fn ) {
if ( div.parentNode ) {
div.parentNode.removeChild( div );
}
- // wangEditor memory in IE
+ // release memory in IE
div = null;
}
}
diff --git a/www/static/admin/js/udeitor/ueditor.config.js b/www/static/admin/js/udeitor/ueditor.config.js
index aca4089da..f15d008f9 100644
--- a/www/static/admin/js/udeitor/ueditor.config.js
+++ b/www/static/admin/js/udeitor/ueditor.config.js
@@ -20,7 +20,7 @@
* window.UEDITOR_HOME_URL = "/xxxx/xxxx/";
*/
var URL = window.UEDITOR_HOME_URL || getUEBasePath();
- ///console.log(getUEBasePath());
+
/**
* 配置项主体。注意,此处所有涉及到路径的配置别遗漏URL变量。
*/
@@ -32,7 +32,7 @@
// 服务器统一请求接口路径
, serverUrl: "/admin/ueditor/index"
- //工具栏上的所有的功能按钮和下拉框,可以在new编辑器的实例时选择自己需要的从新定义
+ //工具栏上的所有的功能按钮和下拉框,可以在new编辑器的实例时选择自己需要的重新定义
, toolbars: [[
'fullscreen', 'source', '|', 'undo', 'redo', '|',
'bold', 'italic', 'underline', 'fontborder', 'strikethrough', 'superscript', 'subscript', 'removeformat', 'formatmatch', 'autotypeset', 'blockquote', 'pasteplain', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', 'selectall', 'cleardoc', '|',
@@ -44,14 +44,13 @@
'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', 'help', 'drafts'
+ 'print', 'preview', 'searchreplace', 'drafts', 'help'
]]
//当鼠标放在工具栏上时显示的tooltip提示,留空支持自动多语言配置,否则以配置值为准
//,labelMap:{
// 'anchor':'', 'undo':''
//}
- //抓取远程图片是否开启,默认true
- ,catchRemoteImageEnable:true
+
//语言配置项,默认是zh-cn。有需要的话也可以使用如下这样的方式来自动多语言切换,当然,前提条件是lang文件夹下存在对应的语言文件:
//lang值也可以通过自动获取 (navigator.language||navigator.browserLanguage ||navigator.userLanguage).toLowerCase()
//,lang:"zh-cn"
@@ -62,7 +61,7 @@
//,theme:'default'
//,themePath:URL +"themes/"
- ,zIndex : 99999 //编辑器层级的基数,默认是900
+ //,zIndex : 900 //编辑器层级的基数,默认是900
//针对getAllHtml方法,会在对应的head标签中增加该编码设置。
//,charset:"utf-8"
@@ -84,14 +83,14 @@
//如果自定义,最好给p标签如下的行高,要不输入中文时,会有跳动感
//,initialStyle:'p{line-height:1em}'//编辑器层级的基数,可以用来改变字体等
- //,iframeCssUrl: URL + '/themes/iframe.css' //给编辑器内部引入一个css文件
+ //,iframeCssUrl: URL + '/themes/iframe.css' //给编辑区域的iframe引入一个css文件
//indentValue
//首行缩进距离,默认是2em
//,indentValue:'2em'
//,initialFrameWidth:1000 //初始化编辑器宽度,默认1000
- // ,initialFrameHeight:600 //初始化编辑器高度,默认320
+ //,initialFrameHeight:320 //初始化编辑器高度,默认320
//,readonly : false //编辑器初始化结束后,编辑区域是否是只读的,默认是false
@@ -140,6 +139,7 @@
// }
// }
//}()
+
//,allHtmlEnabled:false //提交到后台的数据是否包含整个html字符串
//insertorderedlist
@@ -281,18 +281,21 @@
//scaleEnabled
//是否可以拉伸长高,默认true(当开启时,自动长高失效)
- ,scaleEnabled:true
- // ,minFrameWidth:400 //编辑器拖动时最小宽度,默认800
+ //,scaleEnabled:false
+ //,minFrameWidth:800 //编辑器拖动时最小宽度,默认800
//,minFrameHeight:220 //编辑器拖动时最小高度,默认220
//autoFloatEnabled
//是否保持toolbar的位置不动,默认true
- ,autoFloatEnabled:false
+ //,autoFloatEnabled:true
//浮动时工具栏距离浏览器顶部的高度,用于某些具有固定头部的页面
- // ,topOffset:60
+ //,topOffset:30
//编辑器底部距离工具栏高度(如果参数大于等于编辑器高度,则设置无效)
//,toolbarTopOffset:400
+ //设置远程图片是否抓取到本地保存
+ //,catchRemoteImageEnable: true //设置是否抓取远程图片
+
//pageBreakTag
//分页标识符,默认是_ueditor_page_break_tag_
//,pageBreakTag:'_ueditor_page_break_tag_'
@@ -321,7 +324,7 @@
//表格是否可以拖拽
//,tableDragable: true
- //,disabledTableInTable:true //禁止表格嵌套
+
//sourceEditor
//源码的查看方式,codemirror 是代码高亮,textarea是文本框,默认是codemirror
@@ -341,8 +344,89 @@
// 'anchor':'~/dialogs/anchor/anchor.html',
//}
+ //allowLinkProtocol 允许的链接地址,有这些前缀的链接地址不会自动添加http
+ //, allowLinkProtocols: ['http:', 'https:', '#', '/', 'ftp:', 'mailto:', 'tel:', 'git:', 'svn:']
+
//webAppKey 百度应用的APIkey,每个站长必须首先去百度官网注册一个key后方能正常使用app功能,注册介绍,http://app.baidu.com/static/cms/getapikey.html
//, webAppKey: ""
+
+ //默认过滤规则相关配置项目
+ //,disabledTableInTable:true //禁止表格嵌套
+ //,allowDivTransToP:true //允许进入编辑器的div标签自动变成p标签
+ //,rgb2Hex:true //默认产出的数据中的color自动从rgb格式变成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) {
diff --git a/www/static/admin/js/udeitor/ueditor.parse.min.js b/www/static/admin/js/udeitor/ueditor.parse.min.js
index 91995ae57..af057a186 100644
--- a/www/static/admin/js/udeitor/ueditor.parse.min.js
+++ b/www/static/admin/js/udeitor/ueditor.parse.min.js
@@ -4,4 +4,4 @@
* build: Wed Aug 10 2016 11:06:05 GMT+0800 (CST)
*/
-!function(){!function(){UE=window.UE||{};var a=!!window.ActiveXObject,b={removeLastbs:function(a){return a.replace(/\/$/,"")},extend:function(a,b){for(var c=arguments,d=!!this.isBoolean(c[c.length-1])&&c[c.length-1],e=this.isBoolean(c[c.length-1])?c.length-1:c.length,f=1;f=c&&a===b)return d=e,!1}),d},hasClass:function(a,b){b=b.replace(/(^[ ]+)|([ ]+$)/g,"").replace(/[ ]{2,}/g," ").split(" ");for(var c,d=0,e=a.className;c=b[d++];)if(!new RegExp("\\b"+c+"\\b","i").test(e))return!1;return d-1==b.length},addClass:function(a,c){if(a){c=this.trim(c).replace(/[ ]{2,}/g," ").split(" ");for(var d,e=0,f=a.className;d=c[e++];)new RegExp("\\b"+d+"\\b").test(f)||(f+=" "+d);a.className=b.trim(f)}},removeClass:function(a,b){b=this.isArray(b)?b:this.trim(b).replace(/[ ]{2,}/g," ").split(" ");for(var c,d=0,e=a.className;c=b[d++];)e=e.replace(new RegExp("\\b"+c+"\\b"),"");e=this.trim(e).replace(/[ ]{2,}/g," "),a.className=e,!e&&a.removeAttribute("className")},on:function(a,c,d){var e=this.isArray(c)?c:c.split(/\s+/),f=e.length;if(f)for(;f--;)if(c=e[f],a.addEventListener)a.addEventListener(c,d,!1);else{d._d||(d._d={els:[]});var g=c+d.toString(),h=b.indexOf(d._d.els,a);d._d[g]&&h!=-1||(h==-1&&d._d.els.push(a),d._d[g]||(d._d[g]=function(a){return d.call(a.srcElement,a||window.event)}),a.attachEvent("on"+c,d._d[g]))}a=null},off:function(a,c,d){var e=this.isArray(c)?c:c.split(/\s+/),f=e.length;if(f)for(;f--;)if(c=e[f],a.removeEventListener)a.removeEventListener(c,d,!1);else{var g=c+d.toString();try{a.detachEvent("on"+c,d._d?d._d[g]:d)}catch(h){}if(d._d&&d._d[g]){var i=b.indexOf(d._d.els,a);i!=-1&&d._d.els.splice(i,1),0==d._d.els.length&&delete d._d[g]}}},loadFile:function(){function a(a,c){try{for(var d,e=0;d=b[e++];)if(d.doc===a&&d.url==(c.src||c.href))return d}catch(f){return null}}var b=[];return function(c,d,e){var f=a(c,d);if(f)return void(f.ready?e&&e():f.funs.push(e));if(b.push({doc:c,url:d.src||d.href,funs:[e]}),!c.body){var g=[];for(var h in d)"tag"!=h&&g.push(h+'="'+d[h]+'"');return void c.write("<"+d.tag+" "+g.join(" ")+" >"+d.tag+">")}if(!d.id||!c.getElementById(d.id)){var i=c.createElement(d.tag);delete d.tag;for(var h in d)i.setAttribute(h,d[h]);i.onload=i.onreadystatechange=function(){if(!this.readyState||/loaded|complete/.test(this.readyState)){if(f=a(c,d),f.funs.length>0){f.ready=1;for(var b;b=f.funs.pop();)b()}i.onload=i.onreadystatechange=null}},i.onerror=function(){throw Error("The load "+(d.href||d.src)+" fails,check the url")},c.getElementsByTagName("head")[0].appendChild(i)}}}()};b.each(["String","Function","Array","Number","RegExp","Object","Boolean"],function(a){b["is"+a]=function(b){return Object.prototype.toString.apply(b)=="[object "+a+"]"}});var c={};UE.parse={register:function(a,b){c[a]=b},load:function(a){b.each(c,function(c){c.call(a,b)})}},uParse=function(a,c){b.domReady(function(){var d;if(document.querySelectorAll)d=document.querySelectorAll(a);else if(/^#/.test(a))d=[document.getElementById(a.replace(/^#/,""))];else if(/^\./.test(a)){var d=[];b.each(document.getElementsByTagName("*"),function(b){b.className&&new RegExp("\\b"+a.replace(/^\./,"")+"\\b","i").test(b.className)&&d.push(b)})}else d=document.getElementsByTagName(a);b.each(d,function(d){UE.parse.load(b.extend({root:d,selector:a},c))})})}}(),UE.parse.register("insertcode",function(a){var b=this.root.getElementsByTagName("pre");if(b.length)if("undefined"==typeof XRegExp){var c,d;void 0!==this.rootPath?(c=a.removeLastbs(this.rootPath)+"/third-party/SyntaxHighlighter/shCore.js",d=a.removeLastbs(this.rootPath)+"/third-party/SyntaxHighlighter/shCoreDefault.css"):(c=this.highlightJsUrl,d=this.highlightCssUrl),a.loadFile(document,{id:"syntaxhighlighter_css",tag:"link",rel:"stylesheet",type:"text/css",href:d}),a.loadFile(document,{id:"syntaxhighlighter_js",src:c,tag:"script",type:"text/javascript",defer:"defer"},function(){a.each(b,function(a){a&&/brush/i.test(a.className)&&SyntaxHighlighter.highlight(a)})})}else a.each(b,function(a){a&&/brush/i.test(a.className)&&SyntaxHighlighter.highlight(a)})}),UE.parse.register("table",function(a){function b(b,c){var d,e=b;for(c=a.isArray(c)?c:[c];e;){for(d=0;d0){var g=a[c];a[c]=a[e],a[e]=g}return a}function e(b){if(!a.hasClass(b.rows[0],"firstRow")){for(var c=1;c=c&&a===b)return d=e,!1}),d},hasClass:function(a,b){b=b.replace(/(^[ ]+)|([ ]+$)/g,"").replace(/[ ]{2,}/g," ").split(" ");for(var c,d=0,e=a.className;c=b[d++];)if(!new RegExp("\\b"+c+"\\b","i").test(e))return!1;return d-1==b.length},addClass:function(a,c){if(a){c=this.trim(c).replace(/[ ]{2,}/g," ").split(" ");for(var d,e=0,f=a.className;d=c[e++];)new RegExp("\\b"+d+"\\b").test(f)||(f+=" "+d);a.className=b.trim(f)}},removeClass:function(a,b){b=this.isArray(b)?b:this.trim(b).replace(/[ ]{2,}/g," ").split(" ");for(var c,d=0,e=a.className;c=b[d++];)e=e.replace(new RegExp("\\b"+c+"\\b"),"");e=this.trim(e).replace(/[ ]{2,}/g," "),a.className=e,!e&&a.removeAttribute("className")},on:function(a,c,d){var e=this.isArray(c)?c:c.split(/\s+/),f=e.length;if(f)for(;f--;)if(c=e[f],a.addEventListener)a.addEventListener(c,d,!1);else{d._d||(d._d={els:[]});var g=c+d.toString(),h=b.indexOf(d._d.els,a);d._d[g]&&h!=-1||(h==-1&&d._d.els.push(a),d._d[g]||(d._d[g]=function(a){return d.call(a.srcElement,a||window.event)}),a.attachEvent("on"+c,d._d[g]))}a=null},off:function(a,c,d){var e=this.isArray(c)?c:c.split(/\s+/),f=e.length;if(f)for(;f--;)if(c=e[f],a.removeEventListener)a.removeEventListener(c,d,!1);else{var g=c+d.toString();try{a.detachEvent("on"+c,d._d?d._d[g]:d)}catch(h){}if(d._d&&d._d[g]){var i=b.indexOf(d._d.els,a);i!=-1&&d._d.els.splice(i,1),0==d._d.els.length&&delete d._d[g]}}},loadFile:function(){function a(a,c){try{for(var d,e=0;d=b[e++];)if(d.doc===a&&d.url==(c.src||c.href))return d}catch(f){return null}}var b=[];return function(c,d,e){var f=a(c,d);if(f)return void(f.ready?e&&e():f.funs.push(e));if(b.push({doc:c,url:d.src||d.href,funs:[e]}),!c.body){var g=[];for(var h in d)"tag"!=h&&g.push(h+'="'+d[h]+'"');return void c.write("<"+d.tag+" "+g.join(" ")+" >"+d.tag+">")}if(!d.id||!c.getElementById(d.id)){var i=c.createElement(d.tag);delete d.tag;for(var h in d)i.setAttribute(h,d[h]);i.onload=i.onreadystatechange=function(){if(!this.readyState||/loaded|complete/.test(this.readyState)){if(f=a(c,d),f.funs.length>0){f.ready=1;for(var b;b=f.funs.pop();)b()}i.onload=i.onreadystatechange=null}},i.onerror=function(){throw Error("The load "+(d.href||d.src)+" fails,check the url")},c.getElementsByTagName("head")[0].appendChild(i)}}}()};b.each(["String","Function","Array","Number","RegExp","Object","Boolean"],function(a){b["is"+a]=function(b){return Object.prototype.toString.apply(b)=="[object "+a+"]"}});var c={};UE.parse={register:function(a,b){c[a]=b},load:function(a){b.each(c,function(c){c.call(a,b)})}},uParse=function(a,c){b.domReady(function(){var d;if(document.querySelectorAll)d=document.querySelectorAll(a);else if(/^#/.test(a))d=[document.getElementById(a.replace(/^#/,""))];else if(/^\./.test(a)){var d=[];b.each(document.getElementsByTagName("*"),function(b){b.className&&new RegExp("\\b"+a.replace(/^\./,"")+"\\b","i").test(b.className)&&d.push(b)})}else d=document.getElementsByTagName(a);b.each(d,function(d){UE.parse.load(b.extend({root:d,selector:a},c))})})}}(),UE.parse.register("insertcode",function(a){var b=this.root.getElementsByTagName("pre");if(b.length)if("undefined"==typeof XRegExp){var c,d;void 0!==this.rootPath?(c=a.removeLastbs(this.rootPath)+"/third-party/SyntaxHighlighter/shCore.js",d=a.removeLastbs(this.rootPath)+"/third-party/SyntaxHighlighter/shCoreDefault.css"):(c=this.highlightJsUrl,d=this.highlightCssUrl),a.loadFile(document,{id:"syntaxhighlighter_css",tag:"link",rel:"stylesheet",type:"text/css",href:d}),a.loadFile(document,{id:"syntaxhighlighter_js",src:c,tag:"script",type:"text/javascript",defer:"defer"},function(){a.each(b,function(a){a&&/brush/i.test(a.className)&&SyntaxHighlighter.highlight(a)})})}else a.each(b,function(a){a&&/brush/i.test(a.className)&&SyntaxHighlighter.highlight(a)})}),UE.parse.register("table",function(a){function b(b,c){var d,e=b;for(c=a.isArray(c)?c:[c];e;){for(d=0;d0){var g=a[c];a[c]=a[e],a[e]=g}return a}function e(b){if(!a.hasClass(b.rows[0],"firstRow")){for(var c=1;c