diff --git a/css/redactor.css b/css/redactor.css
index b179cfd42fe90e378a3ed32c0340f07d811a0cbe..2297d6f160222d591cd3752bc670ef97d0f16469 100644
--- a/css/redactor.css
+++ b/css/redactor.css
@@ -28,6 +28,29 @@ body .redactor_box_fullscreen {
 	padding: 0;
 }
 
+.redactor-link-tooltip {
+	position: absolute;
+	z-index: 3000;
+	padding: 10px;
+	line-height: 1;
+	display: inline-block;
+	background-color: #000;
+	color: #555 !important;
+}
+.redactor-link-tooltip,
+.redactor-link-tooltip a {
+	font-size: 12px;
+	font-family: Arial, Helvetica, Verdana, Tahoma, sans-serif !important;
+}
+.redactor-link-tooltip a {
+	color: #ccc;
+	margin: 0 5px;
+	text-decoration: none;
+}
+.redactor-link-tooltip a:hover {
+	color: #fff;
+}
+
 .redactor_box textarea, .redactor_box textarea:focus {
 	position: relative;
 	z-index: 1004;
@@ -494,9 +517,8 @@ body .redactor_toolbar li a.redactor_btn_pre		 		{ background-position: -875px;
 	z-index: 2004;
 	padding: 10px;
 	width: 200px;
-	border: 1px solid #ccc;
 	background-color: #fff;
-	box-shadow: 0 2px 4px #ccc;
+	box-shadow: 0 1px 5px #bbb;
 	font-size: 13px;
 	font-family: Helvetica, Arial, Verdana, Tahoma, sans-serif;
 	line-height: 21px;
@@ -537,7 +559,7 @@ body .redactor_toolbar li a.redactor_btn_pre		 		{ background-position: -875px;
 
 #redactor_modal {
 	position: fixed;
-	top: 30%;
+	top: 50%;
 	left: 50%;
   	z-index: 50001;
 	padding: 0;
@@ -682,37 +704,42 @@ body .redactor_toolbar li a.redactor_btn_pre		 		{ background-position: -875px;
 	margin-left: 8px;
 	padding: 6px 16px 5px 16px;
 	outline: none;
-	border: 1px solid #ccc;
-	border-bottom-color: #aaa;
-	border-radius: 4px;
-	background-color: #f3f3f3;
-	background-image: -moz-linear-gradient(top, #ffffff, #e1e1e1);
-	background-image: -ms-linear-gradient(top, #ffffff, #e1e1e1);
-	background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), to(#e1e1e1));
-	background-image: -webkit-linear-gradient(top, #ffffff, #e1e1e1);
-	background-image: -o-linear-gradient(top, #ffffff, #e1e1e1);
-	background-image: linear-gradient(top, #ffffff, #e1e1e1);
-	box-shadow: 0 1px 1px rgba(0, 0, 0, .1);
+	border: none;
+	border-radius: 3px;
+	background-color: #ddd;
 	color: #000;
 	text-align: center;
 	text-decoration: none;
-	text-shadow: 0 1px 0px #ffffff;
 	font-weight: normal;
 	font-size: 12px;
 	font-family: Helvetica, Arial, Verdana, Tahoma, sans-serif;
 	line-height: 1;
-	filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#e1e1e1', GradientType=0);
 	cursor: pointer;
 }
 .redactor_modal_btn:hover {
-	color: #555;
+	color: #777;
 	background: none;
-	background: #f3f3f3;
+	background: #bbb;
 	text-decoration: none;
-	text-shadow: 0 1px 0px rgba(255, 255, 255, 0.8);
-	filter: none;
 }
-
+.redactor_modal_delete_btn {
+	background: none;
+	color: #fff;
+	background-color: #b52525;
+}
+.redactor_modal_delete_btn:hover {
+	color: rgba(255, 255, 255, .6);
+	background-color: #881b1b;
+}
+.redactor_modal_action_btn {
+	background: none;
+	color: #fff;
+	background-color: #2461b5;
+}
+.redactor_modal_action_btn:hover {
+	color: rgba(255, 255, 255, .6);
+	background-color: #1a4580;
+}
 
 /* Drag and Drop Area */
 .redactor_droparea {
diff --git a/js/redactor.min.js b/js/redactor.min.js
index 7a93685e420c853d44d216e29e9021c726a7461a..83ddc777186605a0cb012fb1625def5396d7844a 100644
--- a/js/redactor.min.js
+++ b/js/redactor.min.js
@@ -1,6 +1,6 @@
 /*
-	Redactor v9.1.1
-	Updated: Aug 12, 2013
+	Redactor v9.1.6
+	Updated: Oct 16, 2013
 
 	http://imperavi.com/redactor/
 
@@ -9,4 +9,4 @@
 
 	Usage: $('#content').redactor();
 */
-eval(function(p,a,c,k,e,d){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('(B(d){y b=0;y a=E;"iO iS";y e=B(f){7[0]=f.iR;7[1]=f.dR;7.4C=f;F 7};e.3X.bx=B(){F 7[0]===7[1]};d.fn.M=B(g){y h=[];y f=jh.3X.j9.3t(jb,1);if(1r g==="jc"){7.18(B(){y j=d.1g(7,"M");if(1r j!=="1l"&&d.5J(j[g])){y i=j[g].e1(j,f);if(i!==1l&&i!==j){h.21(i)}}G{F d.33(\'jg jf 5m "\'+g+\'" 2K 4a\')}})}G{7.18(B(){if(!d.1g(7,"M")){d.1g(7,"M",c(7,g))}})}if(h.11===0){F 7}G{if(h.11===1){F h[0]}G{F h}}};B c(g,f){F 1R c.3X.5n(g,f)}d.4a=c;d.4a.iI="9.1.1";d.4a.C={2J:E,1n:E,2Y:E,T:E,by:"en",4m:"i8",3P:E,d4:E,cE:L,c3:L,cz:L,f1:E,db:L,8O:E,3Y:L,1s:E,5G:E,4f:L,5H:E,5I:L,5b:E,6R:60,af:E,7Q:E,7X:E,5Q:"8x://",cy:E,5V:E,3b:E,5R:E,7L:L,8T:E,d2:L,a7:["1b/cI","1b/cN","1b/cF"],6g:E,36:E,3r:L,9K:L,c9:L,2b:E,ct:["4L","|","3i","3d","47","|","4s","4p","55","4M"],19:L,3V:E,8y:Q,bW:0,7g:E,8n:E,cq:L,5y:\'<1D X="i5"></1D>\',cp:{},cm:[],3g:["U","|","4L","|","3i","3d","47","|","4s","4p","55","4M","|","1b","2N","2U","1j","2z","|","6z","|","5E"],6q:["47","3d","3i","5u","4s","4p","6l","6u","6o","5i","1j"],9p:{b:"3i",3E:"3i",i:"3d",em:"3d",7p:"47",7I:"47",25:"4s",2v:"4p",u:"5u",2L:"1j",1A:"1j",1j:"1j"},6p:E,cn:["p","2s","2d","h1","h2","h3","h4","h5","h6"],1z:E,4w:L,9o:L,aK:L,6N:E,aL:E,cA:E,61:E,5s:E,5Z:["U","7P","2z","1O","8R","2l","15","i9"],8X:"3E",8E:"em",6E:20,42:[],68:[],4o:E,4i:"<p>&#7r;</p>",1Y:"&#7r;",9I:/^(P|H[1-6]|2G|6I|6H|7m|6F|6t|6m)$/i,4g:["P","bh","bg","bf","bj","bo","bn","bl","b2","b6","7i","bQ","4x","bb","av","6I","6H","7m","6F","6t","6m"],9P:["aT","1O","7P","hr","i?2f","2z","8R","ic","15","2l","1j","4G","2M","8f"],9X:["1D","dt","dt","h[1-6]","3j","2l"],bw:["2s","N","dl","aU","1y","i4","aV","2v","p","2d","4U","1A","8N","2L","25"],8j:["P","bh","bg","bf","bj","bo","bn","bl","b2","b6","7i","2G","4x","bb","av","4F","6I","6H","7m","6F","6t","6m"],bA:{en:{U:"fx",2N:"4n b1",1b:"4n bJ",1j:"9C",2z:"bL",9n:"4n 2z",d6:"bs 2z",5w:"kE",4L:"kC",bN:"kc 1d",aR:"jM",5j:"bD",b0:"5D 1",aY:"5D 2",aZ:"5D 3",aX:"5D 4",aW:"5D 5",3i:"jD",3d:"k5",at:"k8 ba",al:"ka ba",4s:"k2 b9",4p:"k1 b9",55:"jV",4M:"jU",4X:"jT",63:"4n",9Y:"jS",dU:"5B",9O:"4n 9C",9N:"5C 9D jW",9x:"5C 9D jX",9F:"5C 9M bF",ag:"5C 9M bI",ao:"5B 9M",ap:"5B 9D",a4:"5B 9C",fD:"gE",fC:"fX",ak:"5C bp",an:"5B bp",R:"fZ",dF:"g5",28:"g4",1t:"bF",3D:"bI",dJ:"bJ gh bL",1d:"gn",6h:"aB",gu:"9z",fu:"b1 fQ bD",2U:"4n hs",4I:"ev",hy:"gU",a6:"gF",e7:"gM a6",es:"hh 2U hH",ae:"bC 1d bv bu 1t",aJ:"hE 1d",aA:"bC 1d bv bu 3D",9H:"gA 1d",5E:"4n gy gw",47:"gx",aH:"jv",aD:"fV 2z in 1R g1",5u:"gd",6z:"gk",a2:"g9 (ga)",eU:"bs"}}};c.fn=d.4a.3X={2n:{6T:8,ai:46,9t:40,6S:13,9T:27,bV:9,gz:17,gr:91,g7:37,bZ:91},5n:B(g,f){7.$4h=7.$1h=d(g);7.8w=b++;7.C=d.3S({},d.4a.C,7.$4h.1g(),f);7.4P=L;7.fN=[];7.9W=7.$1h.T("1C");7.fK=7.$1h.T("2r");if(7.C.2Y){7.C.1n=L}if(7.C.1z){7.C.4w=E}if(7.C.4w){7.C.1z=E}if(7.C.7g){7.C.3V=L}7.Q=Q;7.2Z=2Z;7.4c=E;7.bG=1R 2F("^<(/?"+7.C.9P.5q("|/?")+"|"+7.C.9X.5q("|")+")[ >]");7.bq=1R 2F("^<(br|/?"+7.C.9P.5q("|/?")+"|/"+7.C.9X.5q("|/")+")[ >]");7.84=1R 2F("^</?("+7.C.bw.5q("|")+")[ >]");7.8Z=1R 2F("^("+7.C.8j.5q("|")+")$","i");if(7.C.1z===E){if(7.C.5s!==E&&d.3G("p",7.C.5s)==="-1"){7.C.5s.21("p")}if(7.C.5Z!==E){y h=d.3G("p",7.C.5Z);if(h!=="-1"){7.C.5Z.7H(h,h)}}}if(7.1J("3a")||7.1J("7y")){7.C.3g=7.aS(7.C.3g,"5E")}7.C.1a=7.C.bA[7.C.by];7.cB()},d8:B(f){F{U:{R:f.U,1c:"8i"},4L:{R:f.4L,1c:"1K",2P:{p:{R:f.bN,1c:"3I"},2s:{R:f.aR,1c:"bc",3e:"hq"},2d:{R:f.5j,1c:"3I",3e:"hk"},h1:{R:f.b0,1c:"3I",3e:"hi"},h2:{R:f.aY,1c:"3I",3e:"hz"},h3:{R:f.aZ,1c:"3I",3e:"hN"},h4:{R:f.aX,1c:"3I",3e:"hJ"},h5:{R:f.aW,1c:"3I",3e:"hD"}}},3i:{R:f.3i,1M:"3i"},3d:{R:f.3d,1M:"3d"},47:{R:f.47,1M:"hB"},5u:{R:f.5u,1M:"5u"},4s:{R:"&hF; "+f.4s,1M:"6b"},4p:{R:"1. "+f.4p,1M:"6v"},55:{R:"< "+f.55,1c:"8A"},4M:{R:"> "+f.4M,1c:"8F"},1b:{R:f.1b,1c:"et"},2N:{R:f.2N,1c:"eL"},2U:{R:f.2U,1c:"e8"},1j:{R:f.1j,1c:"1K",2P:{9O:{R:f.9O,1c:"eH"},gO:{2m:"7f"},9N:{R:f.9N,1c:"eC"},9x:{R:f.9x,1c:"eJ"},9F:{R:f.9F,1c:"eK"},ag:{R:f.ag,1c:"eR"},gQ:{2m:"7f"},ak:{R:f.ak,1c:"eA"},an:{R:f.an,1c:"9c"},gK:{2m:"7f"},ao:{R:f.ao,1c:"ez"},ap:{R:f.ap,1c:"eD"},a4:{R:f.a4,1c:"eE"}}},2z:{R:f.2z,1c:"1K",2P:{2z:{R:f.9n,1c:"eO"},5w:{R:f.5w,1M:"5w"}}},at:{R:f.at,1c:"1K"},al:{R:f.al,1c:"1K"},6z:{R:f.6z,1c:"1K",2P:{6l:{R:f.ae,1c:"85"},6u:{R:f.aJ,1c:"7R"},6o:{R:f.aA,1c:"7V"},5i:{R:f.9H,1c:"7Y"}}},6l:{R:f.ae,1c:"85"},6u:{R:f.aJ,1c:"7R"},6o:{R:f.aA,1c:"7V"},5i:{R:f.9H,1c:"7Y"},5E:{1M:"cw",R:f.5E}}},1f:B(f,g,h){y i=7.C[f+"hb"];if(d.5J(i)){if(g===E){F i.3t(7,h)}G{F i.3t(7,g,h)}}G{F h}},ha:B(){ch(7.6R);d(2Z).2H(".M");7.$4h.2H(".M").hc("M");y g=7.1S();if(7.C.4o){7.$1E.22(7.$1h);7.$1E.1m();7.$1h.1e(g).1K()}G{y f=7.$J;if(7.C.1n){f=7.$4h}7.$1E.22(f);7.$1E.1m();f.2e("31").2e("d9").24("2X").U(g).1K()}if(7.C.2b){d(".87").1m()}},hd:B(){F d.3S({},7)},gX:B(){F 7.$J},gZ:B(){F 7.$1E},h7:B(){F(7.C.1n)?7.$2f:E},h0:B(){F 7.$19},1S:B(){F 7.$1h.1e()},cG:B(){7.$J.24("2X").24("4v");y f=7.5h(7.$2f.1G().6M());7.$J.16({2X:L,4v:7.C.4m});F f},6Q:B(f,g,h){f=f.2W();if(7.C.2Y){7.cO(f)}G{7.cP(f,g)}if(h!==E){7.cc()}},cP:B(f,g){if(g!==E){f=7.8I(f);f=7.5M(f);f=7.8W(f);f=7.7u(f);if(7.C.1z===E){f=7.8V(f)}G{f=f.I(/<p(.*?)>([\\w\\W]*?)<\\/p>/gi,"$2<br>")}}f=7.8U(f);7.$J.U(f);7.12()},cO:B(f){y g=7.8J();7.$2f[0].2q="gY:gV";f=7.8W(f);f=7.7u(f);f=7.62(f);g.7E();g.ci(f);g.cx();if(7.C.2Y){7.$J=7.$2f.1G().V("1O").16({2X:L,4v:7.C.4m})}7.12()},8k:B(f){f=7.8I(f,L);f=7.8V(f);f=7.8U(f);7.$J.U(f);7.12()},12:B(){y f="";7.bB();if(7.C.2Y){f=7.cG()}G{f=7.$J.U()}f=7.95(f);f=7.62(f);f=7.8a(f);f=f.I(/<\\/1D><(25|2v)>([\\w\\W]*?)<\\/(25|2v)>/gi,"<$1>$2</$1></1D>");if(d.2o(f)==="<br>"){f=""}if(f!==""&&7.C.cz){f=7.bM(f)}f=7.1f("h8",E,f);7.$1h.1e(f);7.1f("h9",E,f);if(7.4P===E){7.1f("6n",E,f)}},95:B(f){if(!7.C.2Y){f=7.5M(f)}f=d.2o(f);f=7.cd(f);f=f.I(/&#7r;/gi,"");f=f.I(/&#ca;/gi,"");f=f.I(/&2i;/gi," ");if(7.C.cy){f=f.I(/<a(.*?)2V="bO"(.*?)>/gi,"<a$1$2>");f=f.I(/<a(.*?)>/gi,\'<a$1 2V="bO">\')}f=f.I("<!--?3u","<?3u");f=f.I("?-->","?>");f=f.I(/ 1g-6a=""/gi,"");f=f.I(/<br\\s?\\/?>\\n?<\\/(P|H[1-6]|2G|6I|6H|7m|6F|6t|6m)>/gi,"</$1>");f=f.I(/<O(.*?)id="M-1b-1E"(.*?)>([\\w\\W]*?)<1p(.*?)><\\/O>/i,"$3<1p$4>");f=f.I(/<O(.*?)id="M-1b-9J"(.*?)>(.*?)<\\/O>/i,"");f=f.I(/<O(.*?)id="M-1b-aF"(.*?)>(.*?)<\\/O>/i,"");f=f.I(/<O\\s*?>([\\w\\W]*?)<\\/O>/gi,"$1");f=f.I(/<O(.*?)1g-M="2Q"(.*?)>([\\w\\W]*?)<\\/O>/gi,"<O$1$2>$3</O>");f=f.I(/<O(.*?)1g-M-4B=""(.*?)>([\\w\\W]*?)<\\/O>/gi,"<O$1$2>$3</O>");f=f.I(/<O\\s*?>([\\w\\W]*?)<\\/O>/gi,"$1");f=f.I(/<O\\s*?id="2c-1u(.*?)"(.*?)>([\\w\\W]*?)<\\/O>/gi,"");f=f.I(/<O\\s*?>([\\w\\W]*?)<\\/O>/gi,"$1");f=f.I(/<O>([\\w\\W]*?)<\\/O>/gi,"$1");f=7.cL(f);F f},cB:B(){7.3N="";7.$1E=d(\'<N X="gG" />\');if(7.$1h[0].Y==="gD"){7.C.4o=L}if(7.C.cE===E&&7.4b()){7.cD()}G{7.cC();if(7.C.1n){7.C.4f=E;7.cf()}G{if(7.C.4o){7.cQ()}G{7.cR()}}if(!7.C.1n){7.7S();7.89()}}},cD:B(){if(!7.C.4o){7.$J=7.$1h;7.$J.1T();7.$1h=7.6Y(7.$J);7.$1h.1e(7.3N)}7.$1E.6W(7.$1h).Z(7.$1h)},cC:B(){if(7.C.4o){7.3N=d.2o(7.$1h.1e())}G{7.3N=d.2o(7.$1h.U())}},cQ:B(){7.$J=d("<N />");7.$1E.6W(7.$1h).Z(7.$J).Z(7.$1h);7.d5(7.$J);7.az()},cR:B(){7.$J=7.$1h;7.$1h=7.6Y(7.$J);7.$1E.6W(7.$J).Z(7.$J).Z(7.$1h);7.az()},6Y:B(f){F d("<5t />").16("2m",f.16("id")).T("1C",7.9W)},d5:B(f){d.18(7.$1h.1S(0).3e.3k(/\\s+/),B(g,h){f.23("gL"+h)})},az:B(){7.$J.23("31").16({2X:L,4v:7.C.4m});7.$1h.16("4v",7.C.4m).1T();7.6Q(7.3N,L,E)},7S:B(){y f=7.$J;if(7.C.1n){f=7.$2f}if(7.C.5G){f.16("5G",7.C.5G)}if(7.C.5H){f.T("gR-1C",7.C.5H+"2y")}if(7.C.d4){7.$J.23("d9")}if(!7.C.4f){f.T("1C",7.9W)}},89:B(){7.4P=E;if(7.C.19){7.C.19=7.d8(7.C.1a);7.cs()}7.dj();7.ce();7.8d();if(7.C.5b){7.5b()}2k(d.K(7.5a,7),4);if(7.1J("3Q")){9k{7.Q.1H("gN",E,E);7.Q.1H("hG",E,E)}9j(f){}}if(7.C.1s){2k(d.K(7.1s,7),2x)}if(!7.C.3Y){2k(d.K(B(){7.C.3Y=L;7.8i(E)},7),3Z)}7.1f("5n")},8d:B(){if(7.C.d2){7.$J.1i("5r.M",d.K(7.cX,7))}7.$J.1i("7J.M",d.K(7.cu,7));7.$J.1i("4q.M",d.K(7.c6,7));7.$J.1i("3B.M",d.K(7.cr,7));if(d.5J(7.C.cV)){7.$J.1i("1s.M",d.K(7.C.cV,7))}7.$J.1i("cU.M",d.K(B(){7.4O=E},7));if(d.5J(7.C.cT)){7.$J.1i("cU.M",d.K(7.C.cT,7))}},cX:B(l){l=l.c0||l;if(2Z.7c===1l){F L}y j=l.80.79.11;if(j==0){F L}l.2a();y i=l.80.79[0];if(7.C.a7!==E&&7.C.a7.3x(i.1o)==-1){F L}7.1x();y h=d("<1p>");y f=d(\'<N id="M-1X-a8" X="M-1X M-1X-a5"><N id="M-1X-4S" X="M-1X-4S" 15="2r: 2x%;"></N></N>\');d(Q.1O).Z(f);y g=1R 7c();g.Z("2U",i);d.8z({2S:7.C.3b,dA:"U",1g:g,dg:E,6s:E,df:E,1o:"6k",2O:d.K(B(n){f.4Q("hO",B(){d(7).1m()});y m=d.6i(n);h.16("2q",m.4N).16("id","a8-1b-1u");7.fs(l,h[0]);y o=d(7.$J.V("1p#a8-1b-1u"));if(o.11){o.24("id")}G{o=E}7.12();7.3r();if(o){7.1f("3b",o,m)}},7),33:d.K(B(m){7.1f("8l",m)},7)})},cu:B(g){y h=E;if(7.1J("3K")&&96.98.3x("hM")===-1){y f=7.1J("7N").3k(".");if(f[0]<hK){h=L}}if(h){F L}if(7.1J("7y")){F L}if(7.C.7L&&7.c2(g)){F L}if(7.C.c3){a=L;7.1B();if(!7.4O){if(7.C.4f===L){7.$J.1C(7.$J.1C());7.7t=7.Q.1O.3H}G{7.7t=7.$J.3H()}}y i=7.8e();2k(d.K(B(){y j=7.8e();7.$J.Z(i);7.1k();y l=7.b4(j);7.f3(l);if(7.C.4f===L){7.$J.T("1C","3L")}},7),1)}},c2:B(i){y h=i.c0||i;7.c7=E;if(h.c4.c8){y g=h.c4.c8[0].hn();if(g!==26){7.1x();7.c7=L;y f=1R hm();f.fo=d.K(7.ft,7);f.gC(g);F L}}F E},c6:B(l){if(a){F E}y p=l.6U;y f=l.aE||l.bR;y o=7.3F();y m=7.2D();y i=7.1V();y h=E;7.1f("4q",l);7.5k(E);if((o&&d(o).1S(0).Y==="4F")||(m&&d(m).1S(0).Y==="4F")){h=L;if(p===7.2n.9t){7.7F(i)}}if(p===7.2n.9t){if(o&&d(o).1S(0).Y==="4x"){7.7F(o)}if(m&&d(m).1S(0).Y==="4x"){7.7F(m)}}if(f&&!l.3U){7.5I(l,p)}if(f&&p===90&&!l.3U&&!l.8o){l.2a();if(7.C.42.11){7.fB()}G{7.Q.1H("hp",E,E)}F}G{if(f&&p===90&&l.3U&&!l.8o){l.2a();if(7.C.68.11!=0){7.fw()}G{7.Q.1H("hv",E,E)}F}}if(f&&p===65){7.4O=L}G{if(p!=7.2n.bZ&&!f){7.4O=E}}if(p==7.2n.6S&&!l.3U&&!l.aE&&!l.bR){if(o.3s==1&&(o.Y=="bQ"||o.Y=="gb")){l.2a();7.1x();7.32(Q.3O("br"));7.1f("5F",l);F E}if(h===L){l.2a();7.1x();y j=d(m).1P().1d();7.32(Q.ax("\\n"));if(j.3W(/\\s$/)==-1){7.32(Q.ax("\\n"))}7.12();7.1f("5F",l);F E}G{if(!7.C.1z){if(i&&7.C.9I.3p(i.Y)){7.1x();2k(d.K(B(){y r=7.1V();if(r.Y==="7i"&&!d(r).3c("31")){y q=d("<p>"+7.C.1Y+"</p>");d(r).1U(q);7.3m(q)}},7),1)}G{if(i===E){7.1x();y g=d("<p>"+7.C.1Y+"</p>");7.32(g[0]);7.3m(g);7.1f("5F",l);F E}}}if(7.C.1z){if(i&&7.C.9I.3p(i.Y)){7.1x();2k(d.K(B(){y q=7.1V();if((q.Y==="7i"||q.Y==="P")&&!d(q).3c("31")){7.f2(q)}},7),1)}G{F 7.aN(l)}}if(i.Y=="4x"||i.Y=="av"){F 7.aN(l)}}7.1f("5F",l)}G{if(p===7.2n.6S&&(l.aE||l.3U)){7.1x();l.2a();7.7T()}}if(p===7.2n.bV&&7.C.5I){if(!7.C.c9){F L}if(7.8Y(7.1S())){F L}l.2a();if(h===L&&!l.3U){7.1x();7.32(Q.ax("\\t"));7.12();F E}G{if(!l.3U){7.8F()}G{7.8A()}}F E}if(p===7.2n.6T){if(1r m.Y!=="1l"&&/^(H[1-6])$/i.3p(m.Y)){y g;if(7.C.1z===E){g=d("<p>"+7.C.1Y+"</p>")}G{g=d("<br>"+7.C.1Y)}d(m).1U(g);7.3m(g)}if(1r m.6f!=="1l"&&m.6f!==26){y n=d.2o(m.6f.I(/[^\\eW-~]/g,""));if(m.1m&&m.3s===3&&m.6f.g3(0)==ca&&n==""){m.1m()}}}},aN:B(f){7.1x();f.2a();7.7T();7.1f("5F",f);F},cr:B(l){if(a){F E}y f=l.6U;y h=7.3F();y j=7.2D();if(!7.C.1z&&j.3s==3&&(h==E||h.Y=="fv")){y i=d("<p>").Z(d(j).4K());d(j).1U(i);y g=d(i).5N();if(1r(g[0])!=="1l"&&g[0].Y=="bd"){g.1m()}7.67(i)}if((7.C.aK||7.C.6N||7.C.aL)&&f===7.2n.6S){7.a3(7.C.5Q,7.C.aK,7.C.6N,7.C.aL);if(7.C.6N){7.3r()}}if(7.C.1z===E&&(f===7.2n.ai||f===7.2n.6T)){F 7.b3(l)}7.1f("3B",l);7.12()},ce:B(){if(!7.C.af){F}d.18(7.C.af,d.K(B(f,g){if(as[g]){d.3S(7,as[g]);if(d.5J(as[g].5n)){7.5n()}}},7))},cf:B(){7.cg();if(7.C.4o){7.aq(7.$1h)}G{7.$au=7.$1h.1T();7.$1h=7.6Y(7.$au);7.aq(7.$au)}},aq:B(f){7.$1h.16("4v",7.C.4m).1T();7.$1E.6W(f).Z(7.$2f).Z(7.$1h)},cg:B(){7.$2f=d(\'<1n 15="2r: 2x%;" co="0" />\').7e("ds",d.K(B(){if(7.C.2Y){7.8J();if(7.3N===""){7.3N=7.C.1Y}7.$2f.1G()[0].ci(7.3N);7.$2f.1G()[0].cx();y f=cl(d.K(B(){if(7.$2f.1G().V("1O").U()){ch(f);7.82()}},7),0)}G{7.82()}},7))},8Q:B(){F 7.$2f[0].ac.Q},8J:B(){y f=7.8Q();if(f.cj){f.gg(f.cj)}F f},7U:B(f){f=f||7.C.T;if(7.f6(f)){7.$2f.1G().V("7P").Z(\'<2z 2V="gl" 1N="\'+f+\'" />\')}if(d.gf(f)){d.18(f,d.K(B(h,g){7.7U(g)},7))}},82:B(){7.$J=7.$2f.1G().V("1O").16({2X:L,4v:7.C.4m});if(7.$J[0]){7.Q=7.$J[0].fP;7.2Z=7.Q.fL||2Z}7.7U();if(7.C.2Y){7.8k(7.$J.U())}G{7.6Q(7.3N,L,E)}7.7S();7.89()},cM:B(f){if(7.8Y(f)){if(7.$4h.16("3P")){7.C.3P=7.$4h.16("3P")}if(7.C.3P===""){7.C.3P=E}if(7.C.3P!==E){7.C.1s=E;7.$J.7e("1s.4l",d.K(7.cb,7));F d(\'<O X="4l" 1g-M="2Q">\').16("2X",E).1d(7.C.3P)}}F E},cb:B(){7.$J.V("O.4l").1m();y f="";if(7.C.1z===E){f=7.C.4i}7.$J.2H("1s.4l");7.$J.U(f);if(7.C.1z===E){7.3m(7.$J.6M()[0])}7.12()},cc:B(){7.C.3P=E;7.$J.V("O.4l").1m();7.$J.2H("1s.4l")},cd:B(f){F f.I(/<O X="4l"(.*?)>(.*?)<\\/O>/i,"")},5I:B(g,f){if(!7.C.5I){F}if(!g.8o){if(f===77){7.3R(g,"fT")}G{if(f===66){7.3R(g,"3i")}G{if(f===73){7.3R(g,"3d")}G{if(f===74){7.3R(g,"6b")}G{if(f===75){7.3R(g,"6v")}G{if(f===72){7.3R(g,"jY")}G{if(f===76){7.3R(g,"jZ")}}}}}}}}G{if(f===48){7.3T(g,"p")}G{if(f===49){7.3T(g,"h1")}G{if(f===50){7.3T(g,"h2")}G{if(f===51){7.3T(g,"h3")}G{if(f===52){7.3T(g,"h4")}G{if(f===53){7.3T(g,"h5")}G{if(f===54){7.3T(g,"h6")}}}}}}}}},3R:B(g,f){g.2a();7.1H(f,E)},3T:B(g,f){g.2a();7.3I(f)},1s:B(){if(!7.1J("7y")){7.2Z.2k(d.K(7.9s,7,L),1)}G{7.$J.1s()}},fH:B(){7.9s()},9s:B(h){7.$J.1s();y f=7.2C();f.6x(7.$J[0]);f.6K(h||E);y g=7.1F();g.4E();g.4Z(f)},8i:B(h){y g;if(7.C.3Y){if(h!==E){7.1B()}y f=26;if(7.C.1n){f=7.$2f.1C();if(7.C.2Y){7.$J.24("2X")}7.$2f.1T()}G{f=7.$J.k3();7.$J.1T()}g=7.$1h.1e();7.5z=g;7.$1h.1C(f).1K().1s();7.$1h.1i("4q.M-5t",B(j){if(j.2n===9){y i=d(7);y l=i.1S(0).3m;i.1e(i.1e().ck(0,l)+"\\t"+i.1e().ck(i.1S(0).67));i.1S(0).3m=i.1S(0).67=l+1;F E}});7.cS();7.41("U");7.C.3Y=E}G{g=7.$1h.1T().1e();if(1r 7.5z!=="1l"){7.5z=7.62(7.5z,E)!==7.62(g,E)}if(7.5z){if(7.C.2Y&&g===""){7.8k(g)}G{7.6Q(g);if(7.C.2Y){7.8d()}}}if(7.C.1n){7.$2f.1K()}G{7.$J.1K()}if(7.C.2Y){7.$J.16("2X",L)}7.$1h.2H("4q.M-5t");7.$J.1s();7.1k();7.5a();7.cW();7.9d("U");7.C.3Y=L}},5b:B(){y f=E;7.6R=cl(d.K(B(){y g=7.1S();if(f!==g){d.8z({2S:7.C.5b,1o:"4R",1g:7.$1h.16("2m")+"="+jB(jC(g)),2O:d.K(B(h){7.1f("5b",E,h);f=g},7)})}},7),7.C.6R*jA)},cs:B(){if(7.C.2b){7.C.3g=7.C.ct}G{if(!7.C.cq){y g=7.C.3g.3x("U"),h=7.C.3g[g+1];7.C.3g.7H(g,1);if(h==="|"){7.C.3g.7H(g,1)}}}d.3S(7.C.19,7.C.cp);d.18(7.C.cm,d.K(B(j,l){7.C.3g.21(l)},7));if(7.C.19){d.18(7.C.19.4L.2P,d.K(B(j,l){if(d.3G(j,7.C.cn)=="-1"){aj 7.C.19.4L.2P[j]}},7))}if(7.C.3g.11===0){F E}7.bT();7.$19=d("<25>").23("jx").16("id","jy"+7.8w);if(7.C.2b){7.$2b=d(\'<N X="87">\').16("id","jF"+7.8w).1T();7.$2b.Z(7.$19);d("1O").Z(7.$2b)}G{if(7.C.8n){d(7.C.8n).U(7.$19)}G{7.$1E.4W(7.$19)}}d.18(7.C.3g,d.K(B(l,m){if(m==="|"){7.$19.Z(d(7.C.5y))}G{if(7.C.19[m]){y j=7.C.19[m];if(7.C.5R===E&&m==="2U"){F L}7.$19.Z(d("<1D>").Z(7.5o(m,j)))}}},7));7.$19.V("a").16("5G","-1");if(7.C.3V){7.8q();d(7.C.8y).1i("jO.M",d.K(7.8q,7))}if(7.C.6q){y f=d.K(7.5O,7);7.$J.1i("6Z.M 3B.M",f)}},8q:B(){y j=d(7.C.8y).3H();y h=7.$1E.38().1W;y i=0;y f=h+7.$1E.1C()+40;if(j>h){y g="2x%";if(7.C.7g){i=7.$1E.38().1t;g=7.$1E.bS();7.$19.23("bU")}7.3V=L;7.$19.T({2u:"7C",2r:g,9w:jL,1W:7.C.bW+"2y",1t:i});if(j<f){7.$19.T("bX","dr")}G{7.$19.T("bX","7k")}}G{7.3V=E;7.$19.T({2u:"ed",2r:"3L",1W:0,1t:i});if(7.C.7g){7.$19.2e("bU")}}},bT:B(){if(!7.C.2b){F}7.$J.1i("6Z.M 3B.M",7,d.K(B(g){y i=7.dC();if(g.1o==="6Z"&&i!=""){7.7Z(g)}if(g.1o==="3B"&&g.3U&&i!=""){y f=d(7.5W(7.1F().kd)),h=f.38();h.1C=f.1C();7.7Z(h,L)}},7))},7Z:B(j,f){if(!7.C.2b){F}y i,h;d(".87").1T();if(f){i=j.1t;h=j.1W+j.1C+14;if(7.C.1n){h+=7.$1E.2u().1W-d(7.Q).3H();i+=7.$1E.2u().1t}}G{y g=7.$2b.bS();i=j.fr;if(d(7.Q).2r()<(i+g)){i-=g}h=j.fl+14;if(7.C.1n){h+=7.$1E.2u().1W;i+=7.$1E.2u().1t}G{h+=d(7.Q).3H()}}7.$2b.T({1t:i+"2y",1W:h+"2y"}).1K();7.bY()},bY:B(){if(!7.C.2b){F}y f=d.K(B(g){d(g).1i("ar.M",d.K(B(h){if(d(h.1I).2A(7.$19).11===0){7.$2b.4Q(2x);7.dK();d(g).2H(h)}},7)).1i("4q.M",d.K(B(h){if(h.6U===7.2n.9T){7.1F().kI()}7.$2b.4Q(2x);d(g).2H(h)},7))},7);f(Q);if(7.C.1n){f(7.Q)}},7a:B(){if(!7.C.2b){F}y f=d.K(B(g){d(g).1i("e5.M",d.K(B(h){if(d(h.1I).2A(7.$19).11===0){7.$2b.4Q(2x);d(g).2H(h)}},7))},7);f(Q);if(7.C.1n){f(7.Q)}},d0:B(g,f){d.18(f,d.K(B(j,i){if(!i.3e){i.3e=""}y h;if(i.2m==="7f"){h=d(\'<a X="kK">\')}G{h=d(\'<a 1N="#" X="\'+i.3e+" kG"+j+\'">\'+i.R+"</a>");h.1i("1L",d.K(B(l){if(l.2a){l.2a()}if(7.1J("3a")){l.c1=E}if(i.1f){i.1f.3t(7,j,h,i,l)}if(i.1M){7.1H(i.1M,j)}if(i.1c){7[i.1c](j)}7.5O();if(7.C.2b){7.$2b.4Q(2x)}},7))}g.Z(h)},7))},cv:B(n,i){if(!7.C.3Y){n.2a();F E}y m=7.$19.V(".cZ"+i);y j=7.2t(i);if(j.3c("5c")){7.78()}G{7.78();7.41(i);j.23("5c");y h=j.2u();if(7.3V){h=j.38()}y l=h.1t+"2y";y f=29;if(7.C.2b){m.T({2u:"6j",1t:l,1W:f+"2y"}).1K()}G{if(7.C.3V&&7.3V){m.T({2u:"7C",1t:l,1W:f+"2y"}).1K()}G{m.T({2u:"6j",1t:l,1W:h.1W+f+"2y"}).1K()}}}y g=d.K(B(o){7.c5(o,m)},7);d(Q).7e("1L",g);7.$J.7e("1L",g);n.kM()},78:B(){7.$19.V("a.5c").2e("59").2e("5c");d(".cY").1T()},c5:B(g,f){if(!d(g.1I).3c("5c")){f.2e("5c");7.78()}},5o:B(i,f){y g=d(\'<a 1N="6C:;" R="\'+f.R+\'" X="92 6G\'+i+\'"></a>\');g.1i("1L",d.K(B(j){if(j.2a){j.2a()}if(7.1J("3a")){j.c1=E}if(g.3c("94")){F E}if(7.7z()===E&&!f.1M){7.$J.1s()}if(f.1M){7.$J.1s();7.1H(f.1M,i);7.7a()}G{if(f.1c&&f.1c!=="1K"){7[f.1c](i);7.7a()}G{if(f.1f){f.1f.3t(7,i,g,f,j);7.7a()}G{if(f.2P){7.cv(j,i)}}}}7.5O(E,i)},7));if(f.2P){y h=d(\'<N X="cY cZ\'+i+\'" 15="2p: 28;">\');h.71(7.$19);7.d0(h,f.2P)}F g},2t:B(f){if(!7.C.19){F E}F d(7.$19.V("a.6G"+f))},d7:B(g){y f=7.2t(g);if(f.3c("59")){f.2e("59")}G{f.23("59")}},41:B(f){7.2t(f).23("59")},9d:B(f){7.2t(f).2e("59")},da:B(f){d.18(7.C.19,d.K(B(g){if(g!=f){7.9d(g)}},7))},cW:B(){7.$19.V("a.92").58("a.d1").2e("94")},cS:B(){7.$19.V("a.92").58("a.d1").23("94")},kQ:B(f,g){7.2t(f).23("6G"+g)},kR:B(f,g){7.2t(f).2e("6G"+g)},kN:B(){7.$19.Z(d(7.C.5y))},kL:B(f){7.2t(f).1P().22(d(7.C.5y))},kA:B(f){7.2t(f).1P().34(d(7.C.5y))},kB:B(f){7.2t(f).1P().5N().1m()},km:B(f){7.2t(f).1P().7d().1m()},kn:B(f){if(!7.C.19){F}7.2t(f).1P().23("9f")},kj:B(f){if(!7.C.19){F}7.2t(f).1P().2e("9f")},ki:B(g,h,j,i){if(!7.C.19){F}y f=7.5o(g,{R:h,1f:j,2P:i});7.$19.Z(d("<1D>").Z(f))},ke:B(g,h,j,i){if(!7.C.19){F}y f=7.5o(g,{R:h,1f:j,2P:i});7.$19.4W(d("<1D>").Z(f))},kf:B(m,g,i,l,j){if(!7.C.19){F}y f=7.5o(g,{R:i,1f:l,2P:j});y h=7.2t(m);if(h.2h()!==0){h.1P().22(d("<1D>").Z(f))}G{7.$19.Z(d("<1D>").Z(f))}},kg:B(j,g,i,m,l){if(!7.C.19){F}y f=7.5o(g,{R:i,1f:m,2P:l});y h=7.2t(j);if(h.2h()!==0){h.1P().34(d("<1D>").Z(f))}G{7.$19.Z(d("<1D>").Z(f))}},kp:B(f,h){y g=7.2t(f);if(h){g.1P().5N().1m()}g.1P().2e("9f");g.1m()},5O:B(h,j){y f=7.3F();7.da(j);if(h===E&&j!=="U"){if(d.3G(j,7.C.6q)!=-1){7.d7(j)}F}if(f&&f.Y==="A"){7.$19.V("a.d3").1d(7.C.1a.d6)}G{7.$19.V("a.d3").1d(7.C.1a.9n)}if(7.C.6p){d.18(7.C.6p,d.K(B(l,m){7.C.6q.21(m)},7));d.3S(7.C.9p,7.C.6p)}d.18(7.C.9p,d.K(B(l,m){if(d(f).2A(l,7.$J.1S()[0]).11!=0){7.41(m)}},7));y g=d(f).2A(7.C.4g.2W().30(),7.$J[0]);if(g.11){y i=g.T("1d-7v");kz(i){9g"3D":7.41("6o");6c;9g"b8":7.41("6u");6c;9g"5i":7.41("5i");6c;ku:7.41("6l");6c}}},1M:B(g,h,f){if(g==="b5"&&7.1J("3a")){h="<"+h+">"}if(g==="3z"&&7.1J("3a")){7.$J.1s();7.Q.2c.4Y().8h(h)}G{7.Q.1H(g,E,h)}if(f!==E){7.12()}7.1f("1H",g,h)},1H:B(i,h,q){if(!7.C.3Y){7.$1h.1s();F E}if(i==="3z"){7.7M(h,q);7.1f("1H",i,h);F}if(7.6d("4F")&&!7.C.cA){F E}if(i==="6b"||i==="6v"){7.1x();y r=7.3F();y m=d(r).2A("2v, 25");y l=E;if(m.11){l=L;y o=m[0].Y;if((i==="6b"&&o==="kt")||(i==="6v"&&o==="jJ")){l=E}}7.1B();if(l){y g=7.57();y f=7.2B(g);if(1r g[0]!="1l"&&g.11>1&&g[0].3s==3){f.di(7.1V())}y j="",s="";d.18(f,d.K(B(v,w){if(w.Y=="2G"){y u=d(w);y t=u.4K();t.V("25","2v").1m();if(7.C.1z===E){j+=7.5h(d("<p>").Z(t.1G()))}G{j+=t.U()+"<br>"}if(v==0){u.23("M-ju").7n();s=7.5h(u)}G{u.1m()}}},7));U=7.$J.U().I(s,"</"+o+">"+j+"<"+o+">");7.$J.U(U);7.$J.V(o+":7n").1m()}G{7.Q.1H(i);y r=7.3F();y m=d(r).2A("2v, 25");if(m.11){if((7.1J("3a")||7.1J("3Q"))&&r.Y!=="2G"){d(r).1U(d(r).U())}y n=m.1P();if(7.7o(n)&&7.6L(n[0])){n.1U(n.1G())}}if(7.1J("3Q")){7.$J.1s()}}7.1k();7.12();7.1f("1H",i,h);F}if(i==="5w"){7.1x();y p=7.6d("A");if(p){d(p).1U(d(p).1d());7.12();7.1f("1H",i,h);F}}7.1M(i,h,q);if(i==="cw"){7.$J.V("hr").24("id")}},8F:B(){7.8C("4M")},8A:B(){7.8C("55")},8C:B(i){7.1x();if(i==="4M"){y j=7.1V();7.1B();if(j&&j.Y=="2G"){y o=7.3F();y l=d(o).2A("2v, 25");y n=l[0].Y;y g=7.2B();d.18(g,B(t,u){if(u.Y=="2G"){y r=d(u).7d();if(r.2h()!=0&&r[0].Y=="2G"){y q=r.6M("25, 2v");if(q.2h()==0){r.Z(d("<"+n+">").Z(u))}G{q.Z(u)}}}})}G{if(j===E&&7.C.1z===L){7.1M("5e","2s");y p=7.1V();y j=d(\'<N 1g-6a="">\').U(d(p).U());d(p).1U(j);y h=7.7K(d(j).T("1Z-1t"))+7.C.6E;d(j).T("1Z-1t",h+"2y")}G{y f=7.2B();d.18(f,d.K(B(r,s){y q=E;if(d.3G(s.Y,7.C.4g)!==-1){q=d(s)}G{q=d(s).2A(7.C.4g.2W().30(),7.$J[0])}y t=7.7K(q.T("1Z-1t"))+7.C.6E;q.T("1Z-1t",t+"2y")},7))}}7.1k()}G{7.1B();y j=7.1V();if(j&&j.Y=="2G"){y g=7.2B();y m=0;7.8L(j,m,g)}G{y f=7.2B();d.18(f,d.K(B(r,s){y q=E;if(d.3G(s.Y,7.C.4g)!==-1){q=d(s)}G{q=d(s).2A(7.C.4g.2W().30(),7.$J[0])}y t=7.7K(q.T("1Z-1t"))-7.C.6E;if(t<=0){if(7.C.1z===L&&1r(q.1g("6a"))!=="1l"){q.1U(q.U())}G{q.T("1Z-1t","");7.3C(q,"15")}}G{q.T("1Z-1t",t+"2y")}},7))}7.1k()}},8L:B(f,h,g){if(f&&f.Y=="2G"){y i=d(f).1P().1P();if(i.2h()!=0&&i[0].Y=="2G"){i.22(f)}G{if(1r g[h]!="1l"){f=g[h];h++;7.8L(f,h,g)}G{7.1H("6b")}}}},8U:B(f){y g=7.cM(f);if(g!==E){F g}if(7.C.1z===E){if(f===""){f=7.C.4i}G{if(f.3W(/^<hr\\s?\\/?>$/gi)!==-1){f="<hr>"+7.C.4i}}}F f},8V:B(f){if(7.C.9o){f=f.I(/<N(.*?)>([\\w\\W]*?)<\\/N>/gi,"<p$1>$2</p>")}if(7.C.4w){f=7.7w(f)}F f},8W:B(f){if(7.C.8O){f=f.I(/\\{\\{(.*?)\\}\\}/gi,"<!-- 6A cH $1 -->");f=f.I(/\\{(.*?)\\}/gi,"<!-- 6A $1 -->")}f=f.I(/<2l(.*?)>([\\w\\W]*?)<\\/2l>/gi,\'<R 1o="1d/6C" 15="2p: 28;" X="M-2l-3A"$1>$2</R>\');f=f.I(/<15(.*?)>([\\w\\W]*?)<\\/15>/gi,\'<1w$1 15="2p: 28;" 2V="M-15-3A">$2</1w>\');f=f.I(/<1y(.*?)>([\\w\\W]*?)<\\/1y>/gi,\'<1w$1 2V="M-1y-3A">$2</1w>\');if(7.C.61){f=f.I(/<\\?3u([\\w\\W]*?)\\?>/gi,\'<1w 15="2p: 28;" 2V="M-3u-3A">$1</1w>\')}G{f=f.I(/<\\?3u([\\w\\W]*?)\\?>/gi,"")}F f},cL:B(f){if(7.C.8O){f=f.I(/<!-- 6A cH (.*?) -->/gi,"{{$1}}");f=f.I(/<!-- 6A (.*?) -->/gi,"{$1}")}f=f.I(/<R 1o="1d\\/6C" 15="2p: 28;" X="M-2l-3A"(.*?)>([\\w\\W]*?)<\\/R>/gi,\'<2l$1 1o="1d/6C">$2<\\/2l>\');f=f.I(/<1w(.*?) 15="2p: 28;" 2V="M-15-3A">([\\w\\W]*?)<\\/1w>/gi,"<15$1>$2</15>");f=f.I(/<1w(.*?)2V="M-1y-3A"(.*?)>([\\w\\W]*?)<\\/1w>/gi,"<1y$1$2>$3</1y>");if(7.C.61){f=f.I(/<1w 15="2p: 28;" 2V="M-3u-3A">([\\w\\W]*?)<\\/1w>/gi,"<?3u\\r\\n$1\\r\\n?>")}F f},62:B(g,f){if(f!==E){y f=[];y i=g.1Q(/<(2d|15|2l|R)(.*?)>([\\w\\W]*?)<\\/(2d|15|2l|R)>/gi);if(i===26){i=[]}if(7.C.61){y h=g.1Q(/<\\?3u([\\w\\W]*?)\\?>/gi);if(h){i=d.93(i,h)}}if(i){d.18(i,B(j,l){g=g.I(l,"cK"+j);f.21(l)})}}g=g.I(/\\n/g," ");g=g.I(/[\\t]*/g,"");g=g.I(/\\n\\s*\\n/g,"\\n");g=g.I(/^[\\s\\n]*/g," ");g=g.I(/[\\s\\n]*$/g," ");g=g.I(/>\\s{2,}</g,"><");g=7.cJ(g,f);g=g.I(/\\n\\n/g,"\\n");F g},cJ:B(g,f){if(f===E){F g}d.18(f,B(h,j){g=g.I("cK"+h,j)});F g},8a:B(j){j=j.I(/<O>([\\w\\W]*?)<\\/O>/gi,"$1");j=j.I(/[\\iw-\\iD\\iE]/g,"");y l=["<b>\\\\s*</b>","<b>&2i;</b>","<em>\\\\s*</em>"];y h=["<2d></2d>","<2s>\\\\s*</2s>","<dd></dd>","<dt></dt>","<25></25>","<2v></2v>","<1D></1D>","<1j></1j>","<2L></2L>","<O>\\\\s*<O>","<O>&2i;<O>","<p>\\\\s*</p>","<p></p>","<p>&2i;</p>","<p>\\\\s*<br>\\\\s*</p>","<N>\\\\s*</N>","<N>\\\\s*<br>\\\\s*</N>"];if(7.C.db){h=h.iG(l)}G{h=l}y f=h.11;2K(y g=0;g<f;++g){j=j.I(1R 2F(h[g],"gi"),"")}F j},7w:B(m){m=d.2o(m);if(7.C.1z===L){F m}if(m===""||m==="<p></p>"){F 7.C.4i}m=m+"\\n";y o=[];y l=m.1Q(/<(1j|N|2d|2I)(.*?)>([\\w\\W]*?)<\\/(1j|N|2d|2I)>/gi);if(l===26){l=[]}y n=m.1Q(/<!--([\\w\\W]*?)-->/gi);if(n){l=d.93(l,n)}if(7.C.61){y g=m.1Q(/<1w(.*?)2V="M-3u-3A">([\\w\\W]*?)<\\/1w>/gi);if(g){l=d.93(l,g)}}if(l){d.18(l,B(q,r){o[q]=r;m=m.I(r,"{I"+q+"}\\n")})}m=m.I(/<br \\/>\\s*<br \\/>/gi,"\\n\\n");B j(s,i,q){F m.I(1R 2F(s,i),q)}y f="(iy|U|1O|7P|R|8R|15|2l|2z|1n|1j|2M|8f|iA|ii|ih|4G|2L|1A|8N|N|dl|dd|dt|25|2v|1D|2d|4U|3j|1y|aV|aT|2s|7W|hZ|15|p|h[1-6]|hr|aU|i1|1w|fz|fE|i2|5x|35|hY|hX|hT|hS|hU|hV)";m=j("(<"+f+"[^>]*>)","gi","\\n$1");m=j("(</"+f+">)","gi","$1\\n\\n");m=j("\\r\\n","g","\\n");m=j("\\r","g","\\n");m=j("/\\n\\n+/","g","\\n\\n");y p=m.3k(1R 2F("\\hW*\\n","g"),-1);m="";2K(y h in p){if(p.i3(h)){if(p[h].3W("{I")==-1){m+="<p>"+p[h].I(/^\\n+|\\n+$/g,"")+"</p>"}G{m+=p[h]}}}if(m.3W(/<2s/gi)!==-1){d.18(m.1Q(/<2s(.*?)>([\\w\\W]*?)<\\/2s>/gi),B(q,r){y t="";t=r.I("<p>","");t=t.I("</p>","<br>");m=m.I(r,t)})}m=j("<p>s*</p>","gi","");m=j("<p>([^<]+)</(N|7W|1y)>","gi","<p>$1</p></$2>");m=j("<p>s*(</?"+f+"[^>]*>)s*</p>","gi","$1");m=j("<p>(<1D.+?)</p>","gi","$1");m=j("<p>s*(</?"+f+"[^>]*>)","gi","$1");m=j("(</?"+f+"[^>]*>)s*</p>","gi","$1");m=j("(</?"+f+"[^>]*>)s*<br />","gi","$1");m=j("<br />(s*</?(?:p|1D|N|dl|dd|dt|8N|2d|1A|25|2v)[^>]*>)","gi","$1");m=j("\\n</p>","gi","</p>");m=j("</1D><p>","gi","</1D>");m=j("<p>\\t?\\n?<p>","gi","<p>");m=j("</dt><p>","gi","</dt>");m=j("</dd><p>","gi","</dd>");m=j("<br></p></2s>","gi","</2s>");m=j("<p>    </p>","gi","");d.18(o,B(q,r){m=m.I("{I"+q+"}",r)});F d.2o(m)},7u:B(f){y g="3E";if(7.C.8X==="b"){g="b"}y h="em";if(7.C.8E==="i"){h="i"}f=f.I(/<O 15="3n-15: 3d;">([\\w\\W]*?)<\\/O>/gi,"<"+h+">$1</"+h+">");f=f.I(/<O 15="3n-ib: 3i;">([\\w\\W]*?)<\\/O>/gi,"<"+g+">$1</"+g+">");if(7.C.8X==="3E"){f=f.I(/<b>([\\w\\W]*?)<\\/b>/gi,"<3E>$1</3E>")}G{f=f.I(/<3E>([\\w\\W]*?)<\\/3E>/gi,"<b>$1</b>")}if(7.C.8E==="em"){f=f.I(/<i>([\\w\\W]*?)<\\/i>/gi,"<em>$1</em>")}G{f=f.I(/<em>([\\w\\W]*?)<\\/em>/gi,"<i>$1</i>")}f=f.I(/<7I>([\\w\\W]*?)<\\/7I>/gi,"<7p>$1</7p>");if(!/<O(.*?)1g-M="2Q"(.*?)>([\\w\\W]*?)<\\/O>/gi.3p(f)){f=f.I(/<O(.*?)(?!1g-M="2Q")(.*?)>([\\w\\W]*?)<\\/O>/gi,\'<O$1 1g-M="2Q"$2>$3</O>\')}F f},5M:B(h){if(h==""||1r h=="1l"){F h}y i=E;if(7.C.5s!==E){i=L}y f=i===L?7.C.5s:7.C.5Z;y g=/<\\/?([a-z][a-8p-9]*)\\b[^>]*>/gi;h=h.I(g,B(l,j){if(i===L){F d.3G(j.30(),f)>"-1"?l:""}G{F d.3G(j.30(),f)>"-1"?"":l}});h=7.7u(h);F h},8I:B(f,g){y h=f.1Q(/<(2d|5j)(.*?)>([\\w\\W]*?)<\\/(2d|5j)>/gi);if(h!==26){d.18(h,d.K(B(l,m){y j=m.1Q(/<(2d|5j)(.*?)>([\\w\\W]*?)<\\/(2d|5j)>/i);j[3]=j[3].I(/&2i;/g," ");if(g!==E){j[3]=7.8H(j[3])}f=f.I(m,"<"+j[1]+j[2]+">"+j[3]+"</"+j[1]+">")},7))}F f},8H:B(f){f=3y(f).I(/&8t;/g,"&").I(/&6e;/g,"<").I(/&gt;/g,">").I(/&bz;/g,\'"\');F 3y(f).I(/&/g,"&8t;").I(/</g,"&6e;").I(/>/g,"&gt;").I(/"/g,"&bz;")},bB:B(){y f=7.$J.V("1D, 1p, a, b, 3E, i6, i7, i, em, u, iH, 7I, 7p, O, je");f.58(\'[1g-M="2Q"]\').9h(\'[15*="3n-2h"][15*="5Y-1C"]\').T("3n-2h","").T("5Y-1C","");f.58(\'[1g-M="2Q"]\').9h(\'[15*="7x-5T: dc;"][15*="5Y-1C"]\').T("7x-5T","").T("5Y-1C","");f.58(\'[1g-M="2Q"]\').9h(\'[15*="7x-5T: dc;"]\').T("7x-5T","");f.58(\'[1g-M="2Q"]\').T("5Y-1C","");d.18(f,d.K(B(g,h){7.3C(h,"15")},7));7.$J.V(\'N[15="1d-7v: -3K-3L;"]\').1G().bi()},bM:B(g){y l=0,n=g.11,m=0,f=26,h=26,q="",j="",p="";7.5L=0;2K(;l<n;l++){m=l;if(-1==g.3l(l).3x("<")){j+=g.3l(l);F 7.9b(j)}2E(m<n&&g.4d(m)!="<"){m++}if(l!=m){p=g.3l(l,m-l);if(!p.1Q(/^\\s{2,}$/g)){if("\\n"==j.4d(j.11-1)){j+=7.56()}G{if("\\n"==p.4d(0)){j+="\\n"+7.56();p=p.I(/^\\s+/,"")}}j+=p}if(p.1Q(/\\n/)){j+="\\n"+7.56()}}f=m;2E(m<n&&">"!=g.4d(m)){m++}q=g.3l(f,m-f);l=m;y o;if("!--"==q.3l(1,3)){if(!q.1Q(/--$/)){2E("-->"!=g.3l(m,3)){m++}m+=2;q=g.3l(f,m-f);l=m}if("\\n"!=j.4d(j.11-1)){j+="\\n"}j+=7.56();j+=q+">\\n"}G{if("!"==q[1]){j=7.7A(q+">",j)}G{if("?"==q[1]){j+=q+">\\n"}G{if(o=q.1Q(/^<(2l|15|2d)/i)){o[1]=o[1].30();q=7.9a(q);j=7.7A(q,j);h=3y(g.3l(l+1)).30().3x("</"+o[1]);if(h){p=g.3l(l+1,h);l+=h;j+=p}}G{q=7.9a(q);j=7.7A(q,j)}}}}}F 7.9b(j)},56:B(){y g="";2K(y f=0;f<7.5L;f++){g+="\\t"}F g},9b:B(f){f=f.I(/\\n\\s*\\n/g,"\\n");f=f.I(/^[\\s\\n]*/,"");f=f.I(/[\\s\\n]*$/,"");f=f.I(/<2l(.*?)>\\n<\\/2l>/gi,"<2l$1><\\/2l>");7.5L=0;F f},9a:B(g){y i="";g=g.I(/\\n/g," ");g=g.I(/\\s{2,}/g," ");g=g.I(/^\\s+|\\s+$/g," ");y h="";if(g.1Q(/\\/$/)){h="/";g=g.I(/\\/+$/,"")}y f;2E(f=/\\s*([^= ]+)(?:=(([\'"\']).*?\\3|[^ ]+))?/.1M(g)){if(f[2]){i+=f[1].30()+"="+f[2]}G{if(f[1]){i+=f[1].30()}}i+=" ";g=g.3l(f[0].11)}F i.I(/\\s*$/,"")+h+">"},7A:B(f,h){y g=f.1Q(7.84);if(f.1Q(7.bG)||g){h=h.I(/\\s*$/,"");h+="\\n"}if(g&&"/"==f.4d(1)){7.5L--}if("\\n"==h.4d(h.11-1)){h+=7.56()}if(g&&"/"!=f.4d(1)){7.5L++}h+=f;if(f.1Q(7.bq)||f.1Q(7.84)){h=h.I(/ *$/,"");h+="\\n"}F h},85:B(){7.64("","jo")},7V:B(){7.64("3D","jj")},7R:B(){7.64("b8","jl")},7Y:B(){7.64("5i","j6")},64:B(g,i){7.1x();if(7.88()){7.Q.1H(i,E,E);F L}7.1B();y j=7.1V();if(!j&&7.C.1z){7.1M("5e","2s");y f=7.1V();y j=d(\'<N 1g-6a="">\').U(d(f).U());d(f).1U(j);d(j).T("1d-7v",g);7.3C(j,"15");if(g==""&&1r(d(j).1g("6a"))!=="1l"){d(j).1U(d(j).U())}}G{y h=7.2B();d.18(h,d.K(B(m,n){y l=E;if(d.3G(n.Y,7.C.4g)!==-1){l=d(n)}G{l=d(n).2A(7.C.4g.2W().30(),7.$J[0])}if(l){l.T("1d-7v",g);7.3C(l,"15")}},7))}7.1k();7.12()},b3:B(i){y f=d.2o(7.$J.U());f=f.I(/<br\\s?\\/?>/i,"");y h=f.I(/<p>\\s?<\\/p>/gi,"");if(f===""||h===""){i.2a();y g=d(7.C.4i).1S(0);7.$J.U(g);7.1s()}7.12()},3I:B(f){7.1x();y g=7.2B();7.1B();d.18(g,d.K(B(h,j){if(j.Y!=="2G"){7.5e(f,j)}},7));7.1k();7.12()},5e:B(f,i){if(i===E){i=7.1V()}if(i===E){if(7.C.1z===L){7.1H("b5",f)}F L}y h="";if(f!=="2d"){h=d(i).1G()}G{h=d(i).U();if(d.2o(h)===""){h=\'<O id="2c-1u-1"></O>\'}}if(i.Y==="4F"){f="p"}if(7.C.1z===L&&f==="p"){d(i).1U(d("<N>").Z(h).U()+"<br>")}G{y g=d("<"+f+">").Z(h);d(i).1U(g)}},dG:B(h,f,g){if(g!==E){7.1B()}y i=d("<"+f+"/>");d(h).1U(B(){F i.Z(d(7).1G())});if(g!==E){7.1k()}F i},bc:B(){7.1x();if(7.C.1z===E){7.1B();y l=7.2B();if(l){d.18(l,d.K(B(n,o){if(o.Y==="4x"){7.5e("p",o,E)}G{if(o.Y!=="2G"){7.5e("2s",o,E)}}},7))}7.1k()}G{y j=7.1V();if(j.Y==="4x"){7.1B();d(j).1U(d(j).U()+"<br>");7.1k()}G{y m=7.dH("2s");y h=d(m).U();y g=["25","2v","1j","2L","4G","2M","8f","dl"];d.18(g,B(n,o){h=h.I(1R 2F("<"+o+"(.*?)>","gi"),"");h=h.I(1R 2F("</"+o+">","gi"),"")});y f=7.C.8j;f.21("1A");d.18(f,B(n,o){h=h.I(1R 2F("<"+o+"(.*?)>","gi"),"");h=h.I(1R 2F("</"+o+">","gi"),"<br>")});d(m).U(h);7.8P(m);y i=d(m).5N();if(i.2h()!=0&&i[0].Y==="bd"){i.1m()}}}7.12()},iJ:B(f,h){y g=7.2B();d(g).24(f);7.12()},iK:B(f,h){y g=7.2B();d(g).16(f,h);7.12()},iL:B(g){y f=7.2B();d(f).T(g,"");7.3C(f,"15");7.12()},iM:B(h,g){y f=7.2B();d(f).T(h,g);7.12()},iT:B(g){y f=7.2B();d(f).2e(g);7.3C(f,"X");7.12()},iU:B(g){y f=7.2B();d(f).23(g);7.12()},j1:B(f){7.1B();7.8c(B(g){d(g).2e(f);7.3C(g,"X")});7.1k();7.12()},j2:B(f){y g=7.2D();if(!d(g).3c(f)){7.4B("23",f)}},j3:B(f){7.1B();7.8c(B(g){d(g).T(f,"");7.3C(g,"15")});7.1k();7.12()},j4:B(g,f){7.4B("T",g,f)},j0:B(f){7.1B();y h=7.2C(),i=7.5W(),g=7.57();if(h.4z||h.4H===h.5P&&i){g=d(i)}d(g).24(f);7.bk();7.1k();7.12()},iZ:B(f,g){7.4B("16",f,g)},4B:B(i,f,j){7.1x();7.1B();y g=7.2C();y h=7.5W();if(g.4z||g.4H===g.5P&&h){d(h)[i](f,j)}G{7.Q.1H("5S",E,4);y l=7.$J.V("3n");d.18(l,d.K(B(m,n){7.bm(i,n,f,j)},7))}7.1k();7.12()},bm:B(j,i,f,l){y h=d(i).1P(),g;if(h&&h[0].Y==="8s"&&h[0].iW.11!=0){g=h;d(i).1U(d(i).U())}G{g=d(\'<O 1g-M="2Q" 1g-M-4B>\').Z(d(i).1G());d(i).1U(g)}d(g)[j](f,l);F g},8c:B(j){y g=7.2C(),h=7.5W(),f=7.57(),i;if(g.4z||g.4H===g.5P&&h){f=d(h);i=L}d.18(f,d.K(B(l,m){if(!i&&m.Y!=="8s"){if(m.4e.Y==="8s"&&!d(m.4e).3c("31")){m=m.4e}G{F}}j.3t(7,m)},7))},bk:B(){y f=7.$J.V("O[1g-M-4B]");d.18(f,d.K(B(h,j){y g=d(j);if(g.16("X")===1l&&g.16("15")===1l){g.1G().bi()}},7))},iX:B(f){7.1B();7.Q.1H("5S",E,4);y h=7.$J.V("3n");y g;d.18(h,B(j,m){y l=d("<"+f+"/>").Z(d(m).1G());d(m).1U(l);g=l});7.1k();7.12()},iY:B(f){7.1B();y g=f.fW();y h=7.57();d.18(h,B(j,l){if(l.Y===g){d(l).1U(d(l).1G())}});7.1k();7.12()},7M:B(h,j){y m=7.2D();y i=m.4e;7.$J.1s();7.1x();y f=d("<N>").Z(d.8r(h));h=f.U();h=7.8a(h);f=d("<N>").Z(d.8r(h));y g=7.1V();if(f.1G().11==1){y l=f.1G()[0].Y;if(l!="P"&&l==g.Y||l=="4F"){h=f.1d();f=d("<N>").Z(h)}}if(!7.C.1z&&f.1G().11==1&&f.1G()[0].3s==3&&(7.9q().11>2||(!m||m.Y=="fv"&&!i||i.Y=="fx"))){h="<p>"+h+"</p>"}if(f.1G().11>1&&g||f.1G().is("p, :5x, 25, 2v, N, 1j, 2s, 2d, 7W, 1w, 5x, 35, fE, fz")){if(7.1J("3a")){7.Q.2c.4Y().8h(h)}G{7.Q.1H("3z",E,h)}}G{7.7j(h,E)}if(7.4O){7.2Z.2k(d.K(B(){if(!7.C.1z){7.67(7.$J.1G().fq())}G{7.fH()}},7),1)}7.5a();if(j!==E){7.12()}},7j:B(g,l){y m=7.1F();if(m.2R&&m.44){y f=m.2R(0);f.eX();y h=7.Q.3O("N");h.4y=g;y n=7.Q.b7(),j,i;2E((j=h.8v)){i=n.5d(j)}f.32(n);if(i){f=f.8D();f.fc(i);f.6K(L);m.4E();m.4Z(f)}}if(l!==E){7.12()}},iV:B(g){y f=d(d.8r(g));if(f.11){g=f.1d()}7.$J.1s();if(7.1J("3a")){7.Q.2c.4Y().8h(g)}G{7.Q.1H("3z",E,g)}7.12()},32:B(f){f=f[0]||f;y g=7.1F();if(g.2R&&g.44){4C=g.2R(0);4C.eX();4C.32(f);4C.iN(f);4C.fc(f);g.4E();g.4Z(4C)}},fs:B(j,i){y g;y f=j.fr,m=j.fl;if(7.Q.fe){y l=7.Q.fe(f,m);g=7.2C();g.6y(l.iQ,l.38);g.6K(L);g.32(i)}G{if(7.Q.fi){g=7.Q.fi(f,m);g.32(i)}G{if(1r Q.1O.fg!="1l"){g=7.Q.1O.fg();g.fk(f,m);y h=g.j5();h.fk(f,m);g.jm("jk",h);g.4U()}}}},7F:B(f){if(7.bH()){if(d(d.2o(7.$J.U())).1S(0)!=d.2o(f)&&7.$J.1G().fq()[0]!==f){F E}7.1x();if(7.C.1z===E){y g=d(7.C.4i);d(f).22(g);7.3m(g)}G{y g=d(\'<O id="2c-1u-1">\'+7.C.1Y+"</O>",7.Q)[0];d(f).22(g);d(g).22(7.C.1Y);7.1k()}}},7T:B(){7.1B();7.$J.V("#2c-1u-1").34("<br>"+(7.1J("3K")?7.C.1Y:""));7.1k()},jn:B(){7.1B();7.$J.V("#2c-1u-1").34("<br><br>"+(7.1J("3K")?7.C.1Y:""));7.1k()},f2:B(f){y g=d("<br>"+7.C.1Y);d(f).1U(g);7.3m(g)},f3:B(h){h=7.1f("js",E,h);if(7.C.f1){y g=7.Q.3O("N");h=h.I(/<br>|<\\/H[1-6]>|<\\/p>|<\\/N>/gi,"\\n");g.4y=h;h=g.9l||g.f9;h=h.I("\\n","<br>");h=7.7w(h);7.7s(h)}if(7.6d("4F")){h=7.fa(h);7.7s(h);F L}h=h.I(/<p(.*?)X="jq"([\\w\\W]*?)<\\/p>/gi,"<25><p$2</p>");h=h.I(/<p(.*?)X="jp"([\\w\\W]*?)<\\/p>/gi,"<p$2</p></25>");h=h.I(/<!--[\\s\\S]*?-->|<\\?(?:3u)?[\\s\\S]*?\\?>/gi,"");h=h.I(/(&2i;){2,}/gi,"&2i;");h=h.I(/&2i;/gi," ");h=h.I(/<b\\ja="eZ-1h-1u(.*?)">([\\w\\W]*?)<\\/b>/gi,"$2");h=h.I(/<b(.*?)id="j8-eZ-j7(.*?)">([\\w\\W]*?)<\\/b>/gi,"$3");h=7.5M(h);h=h.I(/<1A><\\/1A>/gi,"[1A]");h=h.I(/<1A>&2i;<\\/1A>/gi,"[1A]");h=h.I(/<1A><br><\\/1A>/gi,"[1A]");h=h.I(/<a(.*?)1N="(.*?)"(.*?)>([\\w\\W]*?)<\\/a>/gi,\'[a 1N="$2"]$4[/a]\');h=h.I(/<1n(.*?)>([\\w\\W]*?)<\\/1n>/gi,"[1n$1]$2[/1n]");h=h.I(/<2N(.*?)>([\\w\\W]*?)<\\/2N>/gi,"[2N$1]$2[/2N]");h=h.I(/<43(.*?)>([\\w\\W]*?)<\\/43>/gi,"[43$1]$2[/43]");h=h.I(/<3w(.*?)>([\\w\\W]*?)<\\/3w>/gi,"[3w$1]$2[/3w]");h=h.I(/<2I(.*?)>([\\w\\W]*?)<\\/2I>/gi,"[2I$1]$2[/2I]");h=h.I(/<5f(.*?)>/gi,"[5f$1]");h=h.I(/<1p(.*?)15="(.*?)"(.*?)>/gi,"[1p$1$3]");h=h.I(/<1p(.*?)>/gi,"[1p$1]");h=h.I(/ X="(.*?)"/gi,"");h=h.I(/<(\\w+)([\\w\\W]*?)>/gi,"<$1>");h=h.I(/<[^\\/>][^>]*>(\\s*|\\t*|\\n*|&2i;|<br>)<\\/[^>]+>/gi,"");h=h.I(/<N>\\s*?\\t*?\\n*?(<25>|<2v>|<p>)/gi,"$1");h=h.I(/\\[1A\\]/gi,"<1A>&2i;</1A>");h=h.I(/\\[a 1N="(.*?)"\\]([\\w\\W]*?)\\[\\/a\\]/gi,\'<a 1N="$1">$2</a>\');h=h.I(/\\[1n(.*?)\\]([\\w\\W]*?)\\[\\/1n\\]/gi,"<1n$1>$2</1n>");h=h.I(/\\[2N(.*?)\\]([\\w\\W]*?)\\[\\/2N\\]/gi,"<2N$1>$2</2N>");h=h.I(/\\[43(.*?)\\]([\\w\\W]*?)\\[\\/43\\]/gi,"<43$1>$2</43>");h=h.I(/\\[3w(.*?)\\]([\\w\\W]*?)\\[\\/3w\\]/gi,"<3w$1>$2</3w>");h=h.I(/\\[2I(.*?)\\]([\\w\\W]*?)\\[\\/2I\\]/gi,"<2I$1>$2</2I>");h=h.I(/\\[5f(.*?)\\]/gi,"<5f$1>");h=h.I(/\\[1p(.*?)\\]/gi,"<1p$1>");if(7.C.9o){h=h.I(/<N(.*?)>([\\w\\W]*?)<\\/N>/gi,"<p>$2</p>");h=h.I(/<\\/N><p>/gi,"<p>");h=h.I(/<\\/p><\\/N>/gi,"</p>")}if(7.6d("2G")){h=h.I(/<p>([\\w\\W]*?)<\\/p>/gi,"$1<br>")}G{h=7.7w(h)}h=h.I(/<O(.*?)>([\\w\\W]*?)<\\/O>/gi,"$2");h=h.I(/<1p>/gi,"");h=h.I(/<[^\\/>][^>][^1p|5f|1h]*>(\\s*|\\t*|\\n*|&2i;|<br>)<\\/[^>]+>/gi,"");h=h.I(/\\n{3,}/gi,"\\n");h=h.I(/<p><p>/gi,"<p>");h=h.I(/<\\/p><\\/p>/gi,"</p>");h=h.I(/<1D>(\\s*|\\t*|\\n*)<p>/gi,"<1D>");h=h.I(/<\\/p>(\\s*|\\t*|\\n*)<\\/1D>/gi,"</1D>");if(7.C.1z===L){h=h.I(/<p(.*?)>([\\w\\W]*?)<\\/p>/gi,"$2<br>")}h=h.I(/<[^\\/>][^>][^1p|5f|1h]*>(\\s*|\\t*|\\n*|&2i;|<br>)<\\/[^>]+>/gi,"");h=h.I(/<1p 2q="3K-jd-2S\\:\\/\\/(.*?)"(.*?)>/gi,"");7.8K=E;if(7.1J("3Q")){if(7.C.7L){y i=h.1Q(/<1p 2q="1g:1b(.*?)"(.*?)>/gi);if(i!==26){7.8K=i;2K(k in i){y f=i[k].I("<1p",\'<1p 1g-3Q-7J-1b="\'+k+\'" \');h=h.I(i[k],f)}}}2E(/<br>$/gi.3p(h)){h=h.I(/<br>$/gi,"")}}h=h.I(/<p>•([\\w\\W]*?)<\\/p>/gi,"<1D>$1</1D>");2E(/<3n>([\\w\\W]*?)<\\/3n>/gi.3p(h)){h=h.I(/<3n>([\\w\\W]*?)<\\/3n>/gi,"$1")}7.7s(h)},fa:B(g){g=g.I(/<br>|<\\/H[1-6]>|<\\/p>|<\\/N>/gi,"\\n");y f=7.Q.3O("N");f.4y=g;F 7.8H(f.9l||f.f9)},7s:B(f){if(7.4O){if(!7.C.1z){7.$J.U(7.C.4i)}G{7.$J.U("")}7.$J.1s()}f=7.1f("ig",E,f);7.7M(f);7.4O=E;2k(d.K(B(){a=E;if(7.8K!==E){7.f7()}},7),2x);if(7.C.4f){d(7.Q.1O).3H(7.7t)}G{7.$J.3H(7.7t)}},f7:B(){y f=7.$J.V("1p[1g-3Q-7J-1b]");d.18(f,d.K(B(j,l){y h=d(l);y g=l.2q.3k(",");y m=g[1];y n=g[0].3k(";")[0].3k(":")[1];d.4R(7.C.8T,{6s:n,1g:m},d.K(B(o){y i=d.6i(o);h.16("2q",i.4N);h.24("1g-3Q-7J-1b");7.12();7.1f("3b",h,i)},7))},7))},ft:B(i){y g=i.1I.ie;y f=g.3k(",");y h=f[1];y j=f[0].3k(";")[0].3k(":")[1];if(7.C.7L){d.4R(7.C.8T,{6s:j,1g:h},d.K(B(n){y m=d.6i(n);y l=\'<1p 2q="\'+m.4N+\'" id="fI-1b-1u" />\';7.1H("3z",l,E);y o=d(7.$J.V("1p#fI-1b-1u"));if(o.11){o.24("id")}G{o=E}7.12();if(o){7.1f("3b",o,m)}},7))}G{7.7M(\'<1p 2q="\'+g+\'" />\')}},1x:B(f){if(f!==1l){7.C.42.21(f)}G{7.1B();7.C.42.21(7.$J.U());7.8B("42")}},fB:B(){if(7.C.42.11===0){7.$J.1s();F}7.1B();7.C.68.21(7.$J.U());7.1k(E,L);7.$J.U(7.C.42.eV());7.1k();2k(d.K(7.5a,7),2x)},fw:B(){if(7.C.68.11===0){7.$J.1s();F E}7.1B();7.C.42.21(7.$J.U());7.1k(E,L);7.$J.U(7.C.68.eV());7.1k(L);2k(d.K(7.5a,7),4)},5a:B(){7.3r();7.dP()},dP:B(){7.$J.V("1j").1i("1L",d.K(7.97,7))},3r:B(){if(7.C.3r===E){F E}7.$J.V("1p").18(d.K(B(f,g){if(7.1J("3a")){d(g).16("ix","1i")}7.eh(g)},7))},1F:B(){if(!7.C.2J){F 7.Q.1F()}G{if(!7.C.1n){F 2J.1F()}G{F 2J.1F(7.$2f[0])}}},2C:B(){if(!7.C.2J){if(7.Q.1F){y f=7.Q.1F();if(f.2R&&f.44){F f.2R(0)}}F 7.Q.4Y()}G{if(!7.C.1n){F 2J.4Y()}G{F 2J.4Y(7.8Q())}}},8P:B(f){7.dS(f)},3m:B(f){7.5X(f[0]||f,0,26,0)},67:B(f){7.5X(f[0]||f,1,26,1)},5X:B(m,l,j,h){if(j==26){j=m}if(h==26){h=l}y g=7.1F();if(!g){F}y f=7.2C();f.6y(m,l);f.6D(j,h);9k{g.4E()}9j(i){}g.4Z(f)},dH:B(f){f=f.30();y i=7.1V();if(i){y j=7.dG(i,f);7.12();F j}y h=7.1F();y g=h.2R(0);y j=Q.3O(f);j.5d(g.iv());g.32(j);7.8P(j);F j},im:B(){y f=7.2C();f.6x(7.$J[0]);y g=7.1F();g.4E();g.4Z(f)},dK:B(){7.1F().4E()},bE:B(i){y f=0;y h=7.2C();y g=h.8D();g.6x(i);g.6D(h.5P,h.dR);f=d.2o(g.2W()).11;F f},bK:B(){F 1R e(7.1F().2R(0))},dS:B(j,g,n){if(1r n==="1l"){n=g}j=j[0]||j;y p=7.2C();p.6x(j);y q=7.8M(j);y m=E;y f=0,r;if(q.11==1&&g){p.6y(q[0],g);p.6D(q[0],n)}G{2K(y o=0,l;l=q[o++];){r=f+l.11;if(!m&&g>=f&&(g<r||(g==r&&o<q.11))){p.6y(l,g-f);m=L}if(m&&n<=r){p.6D(l,n-f);6c}f=r}}y h=7.1F();h.4E();h.4Z(p)},8M:B(l){y j=[];if(l.3s==3){j.21(l)}G{y h=l.9e;2K(y g=0,f=h.11;g<f;++g){j.21.e1(j,7.8M(h[g]))}}F j},1B:B(){if(!7.7z()){7.$J.1s()}if(!7.C.2J){7.e2(7.2C())}G{7.4c=2J.ip()}},e2:B(i,f){if(!i){F}y h=d(\'<O id="2c-1u-1" X="M-2c-1u">\'+7.C.1Y+"</O>",7.Q)[0];y g=d(\'<O id="2c-1u-2" X="M-2c-1u">\'+7.C.1Y+"</O>",7.Q)[0];if(i.4z===L){7.6J(i,h,L)}G{7.6J(i,h,L);7.6J(i,g,E)}7.4c=7.$J.U();7.1k(E,E)},6J:B(f,h,g){y i=f.8D();i.6K(g);i.32(h);i.iu()},1k:B(i,f){if(!7.C.2J){if(i===L&&7.4c){7.$J.U(7.4c)}y h=7.$J.V("O#2c-1u-1");y g=7.$J.V("O#2c-1u-2");if(7.1J("3Q")){7.$J.1s()}G{if(!7.7z()){7.$J.1s()}}if(h.11!=0&&g.11!=0){7.5X(h[0],0,g[0],0)}G{if(h.11!=0){7.5X(h[0],0,26,0)}}if(f!==E){7.8B();7.4c=E}}G{2J.it(7.4c)}},8B:B(f){if(!7.C.2J){d.18(7.$J.V("O.M-2c-1u"),B(){y g=d.2o(d(7).U().I(/[^\\eW-~]/g,""));if(g==""){d(7).1m()}G{d(7).24("X").24("id")}})}G{2J.ir(7.4c)}},2D:B(){y f=E;y g=7.1F();if(g.44>0){f=g.2R(0).4H}F 7.7o(f)},3F:B(f){f=f||7.2D();if(f){F 7.7o(d(f).1P()[0])}G{F E}},1V:B(f){if(1r f==="1l"){f=7.2D()}2E(f){if(7.6L(f)){if(d(f).3c("31")){F E}F f}f=f.4e}F E},2B:B(g){y h=[];if(1r g=="1l"){y f=7.2C();if(f&&f.4z===L){F[7.1V()]}y g=7.57(f)}d.18(g,d.K(B(j,l){if(7.C.1n===E&&d(l).83("N.31").2h()==0){F E}if(7.6L(l)){h.21(l)}},7));if(h.11===0){h=[7.1V()]}F h},6L:B(f){F f.3s==1&&7.8Z.3p(f.kr)},9m:B(f){F 7.8Z.3p(f)},dk:B(j){if(1r j=="1l"||j==E){y j=7.2C()}if(j&&j.4z===L){F[7.2D()]}y f=7.1F();9k{y p=f.2R(0).eG()}9j(n){F(E)}y l=7.Q.3O("O");l.5d(p);2Z.9i=l.9e;y m=9i.11;y g=[];2K(y h=0,o=m;h<o;h++){g.21(9i[h])}if(g.11==0){g.21(7.2D())}F g},57:B(h,f){if(7.C.1z){F 7.dk(h)}if(1r h=="1l"||h==E){y h=7.2C()}if(h&&h.4z===L){if(1r f==="1l"&&7.9m(f)){y l=7.1V();if(l.Y==f){F[l]}G{F[]}}G{F[7.2D()]}}y g=[],j=[];y i=7.Q.1F();if(!i.kv){g=7.9q(i.2R(0))}d.18(g,d.K(B(m,n){if(7.C.1n===E&&d(n).83("N.31").2h()==0){F E}if(1r f==="1l"){if(d.2o(n.9l)!=""){j.21(n)}}G{if(n.Y==f){j.21(n)}}},7));if(j.11==0){if(1r f==="1l"&&7.9m(f)){y l=7.1V();if(l.Y==f){F j.21(l)}G{F[]}}G{j.21(7.2D())}}F j},5W:B(f){if(!f){f=7.2D()}2E(f){if(f.3s==1){if(d(f).3c("31")){F E}F f}f=f.4e}F E},9q:B(g){g=g||7.2C();y h=g.4H;y f=g.5P;if(h==f){F[h]}y i=[];2E(h&&h!=f){i.21(h=7.dq(h))}h=g.4H;2E(h&&h!=g.ky){i.di(h);h=h.4e}F i},dq:B(f){if(f.kx()){F f.8v}G{2E(f&&!f.dB){f=f.4e}if(!f){F 26}F f.dB}},dC:B(){F 7.1F().2W()},kk:B(){y j="";y l=7.1F();if(l.44){y g=7.Q.3O("N");y f=l.44;2K(y h=0;h<f;++h){g.5d(l.2R(h).eG())}j=g.4y}F 7.95(j)},eH:B(){7.1B();7.4J(7.C.1a.1j,7.C.fG,kP,d.K(B(){d("#fb").1L(d.K(7.eI,7));2k(B(){d("#am").1s()},3Z)},7))},eI:B(){y s=d("#am").1e(),g=d("#f8").1e(),o=d("<N></N>"),f=39.de(39.dD()*dy),q=d(\'<1j id="1j\'+f+\'"><4G></4G></1j>\'),h,m,n,p;2K(h=0;h<s;h++){m=d("<2L></2L>");2K(n=0;n<g;n++){p=d("<1A>"+7.C.1Y+"</1A>");if(h===0&&n===0){p.Z(\'<O id="2c-1u-1">\'+7.C.1Y+"</O>")}d(m).Z(p)}q.Z(m)}o.Z(q);y j=o.U();7.2j();7.1k();y l=7.1V()||7.2D();if(l){d(l).22(j)}G{7.7j(j,E)}7.1k();y r=7.$J.V("#1j"+f);7.97(r);7.5O();r.V("O#2c-1u-1").1m();r.24("id");7.12()},97:B(f){7.$1j=d(f.1I||f).2A("1j");7.$4G=d(f.1I).2A("4G");7.$2M=7.$1j.V("2M");7.$81=d(f.1I||7.$1j.V("1A").7b());7.$3v=d(f.1I||7.$1j.V("2L").7b()).2A("2L")},eE:B(){7.1x();if(!7.$1j){F}7.$1j.1m();7.$1j=E;7.12()},eD:B(){7.1x();if(!7.$3v){F}y f=7.$3v.7d().11?7.$3v.7d():7.$3v.5N();if(f.11){y g=f.6M("1A").7b();if(g.11){g.4W(\'<O id="2c-1u-1">\'+7.C.1Y+"</O>");7.1k()}}7.$3v.1m();7.12()},ez:B(){7.1x();y f=7.$81.1S(0).kU;7.$1j.V("2L").18(d.K(B(g,h){y j=f-1<0?f+1:f-1;if(g===0){d(h).V("1A").eq(j).4W(\'<O id="2c-1u-1">\'+7.C.1Y+"</O>");7.1k()}d(h).V("1A").eq(f).1m()},7));7.12()},eA:B(){7.1x();if(7.$1j.V("2M").2h()!==0){7.9c()}G{y f=7.$1j.V("2L").7b().4K();f.V("1A").U(7.C.1Y);7.$2M=d("<2M></2M>");7.$2M.Z(f);7.$1j.4W(7.$2M);7.12()}},9c:B(){7.1x();d(7.$2M).1m();7.$2M=E;7.12()},eC:B(){7.9r("34")},eJ:B(){7.9r("22")},eK:B(){7.8m("34")},eR:B(){7.8m("22")},9r:B(f){7.1x();y g=7.$3v.4K();g.V("1A").U(7.C.1Y);if(f==="22"){7.$3v.22(g)}G{7.$3v.34(g)}7.12()},8m:B(g){7.1x();y f=0;7.$3v.V("1A").18(d.K(B(h,j){if(d(j)[0]===7.$81[0]){f=h}},7));7.$1j.V("2L").18(d.K(B(h,l){y j=d(l).V("1A").eq(f);y m=j.4K();m.U(7.C.1Y);g==="22"?j.22(m):j.34(m)},7));7.12()},eL:B(){7.1B();7.4J(7.C.1a.2N,7.C.f5,jK,d.K(B(){d("#f0").1L(d.K(7.eN,7));2k(B(){d("#9A").1s()},3Z)},7))},eN:B(){y f=d("#9A").1e();f=7.5M(f);7.1k();y g=7.1V()||7.2D();if(g){d(g).22(f)}G{7.7j(f,E)}7.12();7.2j()},eO:B(){7.1B();y f=d.K(B(){7.5v=E;y h=7.1F();y g="",o="",j="";y i=7.3F();y l=d(i).1P().1S(0);if(l&&l.Y==="A"){i=l}if(i&&i.Y==="A"){g=i.1N;o=d(i).1d();j=i.1I;7.5v=i}G{o=h.2W()}d(".6w").1e(o);y q=ex.ew.1N.I(/\\/$/i,"");y n=g.I(q,"");if(7.C.5Q===E){y p=1R 2F("^(8x|8S|6B)://"+ex.ew.jI,"i");n=n.I(p,"")}y m=d("#3M").V("a");if(7.C.7X===E){m.eq(1).1m()}if(7.C.7Q===E){m.eq(2).1m()}if(7.C.7X===E&&7.C.7Q===E){d("#3M").1m();d("#69").1e(n)}G{if(g.3W("6h:")===0){7.ah.3t(7,2);d("#5K").1e(2);d("#ay").1e(g.I("6h:",""))}G{if(n.3W(/^#/gi)===0){7.ah.3t(7,3);d("#5K").1e(3);d("#aI").1e(n.I(/^#/gi,""))}G{d("#69").1e(n)}}}if(j==="5l"){d("#4V").6X("6V",L)}d("#fy").1L(d.K(7.ec,7));2k(B(){d("#69").1s()},3Z)},7);7.4J(7.C.1a.2z,7.C.dM,jH,f)},ec:B(){y j=d("#5K").1e();y h="",n="",l="",m="";if(j==="1"){h=d("#69").1e();n=d("#dO").1e();if(d("#4V").6X("6V")){l=\' 1I="5l"\';m="5l"}y i="((jP--)?[a-8p-9]+(-[a-8p-9]+)*.)+[a-z]{2,}";y g=1R 2F("^(8x|8S|6B)://"+i,"i");y f=1R 2F("^"+i,"i");if(h.3W(g)==-1&&h.3W(f)==0&&7.C.5Q){h=7.C.5Q+h}}G{if(j==="2"){h="6h:"+d("#ay").1e();n=d("#fF").1e()}G{if(j==="3"){h="#"+d("#aI").1e();n=d("#fJ").1e()}}}7.e6(\'<a 1N="\'+h+\'"\'+l+">"+n+"</a>",d.2o(n),h,m)},e6:B(f,i,g,h){7.1k();if(i!==""){if(7.5v){7.1x();d(7.5v).1d(i).16("1N",g);if(h!==""){d(7.5v).16("1I",h)}G{d(7.5v).24("1I")}7.12()}G{7.1M("3z",f)}}7.2j()},e8:B(){7.1B();y f=d.K(B(){y g=7.1F();y h="";if(7.88()){h=g.1d}G{h=g.2W()}d("#9u").1e(h);if(!7.4b()){7.8g("#45",{2S:7.C.5R,36:7.C.36,2O:d.K(7.8u,7),33:d.K(B(j,i){7.1f("e9",i)},7)})}7.a0("45",{3L:L,2S:7.C.5R,2O:d.K(7.8u,7),33:d.K(B(j,i){7.1f("e9",i)},7)})},7);7.4J(7.C.1a.2U,7.C.dp,jE,f)},8u:B(g){7.1k();if(g!==E){y i=d("#9u").1e();if(i===""){i=g.a2}y h=\'<a 1N="\'+g.4N+\'" id="4N-1u">\'+i+"</a>";if(7.1J("3K")&&!!7.2Z.8b){h=h+"&2i;"}7.1H("3z",h,E);y f=d(7.$J.V("a#4N-1u"));if(f.2h()!=0){f.24("id")}G{f=E}7.12();7.1f("5R",f,g)}7.2j()},et:B(){7.1B();y f=d.K(B(){if(7.C.5V){d.k6(7.C.5V,d.K(B(m){y i={},l=0;d.18(m,d.K(B(o,p){if(1r p.6O!=="1l"){l++;i[p.6O]=l}},7));y j=E;d.18(m,d.K(B(r,s){y q="";if(1r s.R!=="1l"){q=s.R}y o=0;if(!d.eu(i)&&1r s.6O!=="1l"){o=i[s.6O];if(j===E){j=".5p"+o}}y p=d(\'<1p 2q="\'+s.k4+\'" X="5p 5p\'+o+\'" 2V="\'+s.1b+\'" R="\'+q+\'" />\');d("#a1").Z(p);d(p).1L(d.K(7.du,7))},7));if(!d.eu(i)){d(".5p").1T();d(j).1K();y n=B(o){d(".5p").1T();d(".5p"+d(o.1I).1e()).1K()};y h=d(\'<4U id="k7">\');d.18(i,B(p,o){h.Z(d(\'<3j 2T="\'+o+\'">\'+p+"</3j>"))});d("#a1").34(h);h.6n(n)}},7))}G{d("#3M").V("a").eq(1).1m()}if(7.C.3b||7.C.6g){if(!7.4b()&&7.C.6g===E){if(d("#45").11){7.8g("#45",{2S:7.C.3b,36:7.C.36,2O:d.K(7.9U,7),33:d.K(B(i,h){7.1f("8l",h)},7)})}}if(7.C.6g===E){7.a0("45",{3L:L,2S:7.C.3b,2O:d.K(7.9U,7),33:d.K(B(i,h){7.1f("8l",h)},7)})}G{d("#45").1i("6n.M",d.K(7.fm,7))}}G{d(".3f").1T();if(!7.C.5V){d("#3M").1m();d("#aG").1K()}G{y g=d("#3M").V("a");g.eq(0).1m();g.eq(1).23("4k");d("#aC").1K()}}d("#dL").1L(d.K(7.dz,7));if(!7.C.3b&&!7.C.5V){2k(B(){d("#4D").1s()},3Z)}},7);7.4J(7.C.1a.1b,7.C.e0,kb,f)},eS:B(h){y f=h;y g=f.1P().1P();y i=d.K(B(){d("#9E").1e(f.16("9R"));d("#fU").16("1N",f.16("2q"));d("#9Z").1e(f.T("4r"));if(d(g).1S(0).Y==="A"){d("#4D").1e(d(g).16("1N"));if(d(g).16("1I")=="5l"){d("#4V").6X("6V",L)}}d("#dV").1L(d.K(B(){7.aw(f)},7));d("#dX").1L(d.K(B(){7.ep(f)},7))},7);7.4J(7.C.1a.1b,7.C.do,g0,i)},aw:B(g){y f=d(g).1P();d(g).1m();if(f.11&&f[0].Y==="P"){7.$J.1s();7.3m(f)}7.1f("g6",g);7.2j();7.12()},ep:B(i){y g=d(i);y h=g.1P();g.16("9R",d("#9E").1e());y n=d("#9Z").1e();if(n==="1t"){g.T({"4r":"1t",1Z:"0 5g 5g 0"})}G{if(n==="3D"){g.T({"4r":"3D",1Z:"0 0 5g 5g"})}G{y l=g.2A("#M-1b-1E");if(l.2h()!=0){l.T({"4r":"",1Z:""})}g.T({"4r":"",1Z:""})}}y j=d.2o(d("#4D").1e());if(j!==""){y m=E;if(d("#4V").6X("6V")){m=L}if(h.1S(0).Y!=="A"){y f=d(\'<a 1N="\'+j+\'">\'+7.5h(i)+"</a>");if(m){f.16("1I","5l")}g.1U(f)}G{h.16("1N",j);if(m){h.16("1I","5l")}G{h.24("1I")}}}G{if(h.1S(0).Y==="A"){h.1U(7.5h(i))}}7.2j();7.3r();7.12()},5k:B(h){if(h!==E&&d(h.1I).1P().2h()!=0&&d(h.1I).1P()[0].id==="M-1b-1E"){F E}y f=7.$J.V("#M-1b-1E");if(f.2h()==0){F E}7.$J.V("#M-1b-aF, #M-1b-9J").1m();y g=f.T("1Z");if(g!="eP"){f.V("1p").T("1Z",g);f.T("1Z","")}f.V("1p").T("eQ","");f.1U(B(){F d(7).1G()});d(Q).2H("1L.M-1b-5U-1T");7.$J.2H("1L.M-1b-5U-1T");7.$J.2H("4q.M-1b-aj");7.12()},eh:B(g){y f=d(g);f.1i("ar",d.K(B(){7.5k(E)},7));f.1i("gc",d.K(B(){7.$J.1i("5r.M-1b-eg-5r",d.K(B(){2k(d.K(B(){7.3r();7.$J.2H("5r.M-1b-eg-5r");7.12()},7),1)},7))},7));f.1i("1L",d.K(B(l){if(7.$J.V("#M-1b-1E").2h()!=0){F E}y n=E,q,p,m=f.2r()/f.1C(),o=20,j=10;y h=7.ee(f);y i=E;h.1i("ar",B(r){i=L;r.2a();m=f.2r()/f.1C();q=39.4t(r.ad-f.eq(0).38().1t);p=39.4t(r.ab-f.eq(0).38().1W)});d(7.Q.1O).1i("e5",d.K(B(v){if(i){y s=39.4t(v.ad-f.eq(0).38().1t)-q;y r=39.4t(v.ab-f.eq(0).38().1W)-p;y u=f.1C();y w=7O(u,10)+r;y t=39.4t(w*m);if(t>o){f.2r(t);if(t<2x){7.4j.T({7B:"-6r",7G:"-gv",5S:"gp",9G:"go eF"})}G{7.4j.T({7B:"-7h",7G:"-eT",5S:"7h",9G:"6r 5g"})}}q=39.4t(v.ad-f.eq(0).38().1t);p=39.4t(v.ab-f.eq(0).38().1W);7.12()}},7)).1i("6Z",B(){i=E});7.$J.1i("4q.M-1b-aj",d.K(B(s){y r=s.6U;if(7.2n.6T==r||7.2n.ai==r){7.5k(E);7.aw(f)}},7));d(Q).1i("1L.M-1b-5U-1T",d.K(7.5k,7));7.$J.1i("1L.M-1b-5U-1T",d.K(7.5k,7))},7))},ee:B(g){y h=d(\'<O id="M-1b-1E" 1g-M="2Q">\');h.T({2u:"ed",2p:"gB-fO",9v:0,fM:"e4 fR fS(0, 0, 0, .6)","4r":g.T("4r")});h.16("2X",E);y i=g.T("1Z");if(i!="eP"){h.T("1Z",i);g.T("1Z","")}g.T("eQ",0.5).22(h);7.4j=d(\'<O id="M-1b-aF" 1g-M="2Q">\'+7.C.1a.eU+"</O>");7.4j.T({2u:"6j",9w:2,1W:"50%",1t:"50%",7B:"-7h",7G:"-eT",9v:1,dx:"#dw",5T:"#e3",5S:"7h",9G:"6r 5g",9S:"fY"});7.4j.16("2X",E);7.4j.1i("1L",d.K(B(){7.eS(g)},7));h.Z(7.4j);y f=d(\'<O id="M-1b-9J" 1g-M="2Q"></O>\');f.T({2u:"6j",9w:2,9v:1,9S:"ht-5U",hj:"-ho",3D:"-eF",hA:"e4 hL #e3",dx:"#dw",2r:"dv",1C:"dv"});f.16("2X",E);h.Z(f);h.Z(g);F f},du:B(g){y f=\'<1p id="1b-1u" 2q="\'+d(g.1I).16("2V")+\'" 9R="\'+d(g.1I).16("R")+\'" />\';if(7.C.4w){f="<p>"+f+"</p>"}7.7l(f,L)},dz:B(){y g=d("#4D").1e();if(g!==""){y f=\'<1p id="1b-1u" 2q="\'+g+\'" />\';if(7.C.1z===E){f="<p>"+f+"</p>"}7.7l(f,L)}G{7.2j()}},9U:B(f){7.7l(f)},7l:B(g,h){7.1k();if(g!==E){y f="";if(h!==L){f=\'<1p id="1b-1u" 2q="\'+g.4N+\'" />\';if(7.C.4w){f="<p>"+f+"</p>"}}G{f=g}7.1H("3z",f,E);y i=d(7.$J.V("1p#1b-1u"));if(i.11){i.24("id")}G{i=E}7.12();h!==L&&7.1f("3b",i,g)}7.2j();7.3r()},dj:B(){d.3S(7.C,{dp:3y()+\'<1w><N id="M-1X" X="M-1X M-1X-a5" 15="2p: 28;"><N id="M-1X-4S" X="M-1X-4S" 15="2r: 2x%;"></N></N><1y id="gS" 5m="4R" 4A="" 70="6P/1y-1g"><1q>\'+7.C.1a.a2+\'</1q><1v 1o="1d" id="9u" X="3q" /><N 15="1Z-1W: 6r;"><1v 1o="2U" id="45" 2m="2U" /></N></1y></1w>\',do:3y()+"<1w><1q>"+7.C.1a.R+\'</1q><1v id="9E" X="3q" /><1q>\'+7.C.1a.2z+\'</1q><1v id="4D" X="3q" /><1q><1v 1o="dN" id="4V"> \'+7.C.1a.aD+"</1q><1q>"+7.C.1a.dF+\'</1q><4U id="9Z"><3j 2T="28">\'+7.C.1a.28+\'</3j><3j 2T="1t">\'+7.C.1a.1t+\'</3j><3j 2T="3D">\'+7.C.1a.3D+\'</3j></4U></1w><35><2g id="dV" X="3h">\'+7.C.1a.dU+\'</2g>&2i;&2i;&2i;<2g X="3h 4T">\'+7.C.1a.4X+\'</2g><1v 1o="2g" 2m="9Y" X="3h" id="dX" 2T="\'+7.C.1a.9Y+\'" /></35>\',e0:3y()+\'<1w><N id="3M"><a 1N="#" X="4k">\'+7.C.1a.4I+\'</a><a 1N="#">\'+7.C.1a.a6+\'</a><a 1N="#">\'+7.C.1a.2z+\'</a></N><N id="M-1X" X="M-1X M-1X-a5" 15="2p: 28;"><N id="M-1X-4S" X="M-1X-4S" 15="2r: 2x%;"></N></N><1y id="gJ" 5m="4R" 4A="" 70="6P/1y-1g"><N id="dQ" X="3f"><1v 1o="2U" id="45" 2m="2U" /></N><N id="aC" X="3f" 15="2p: 28;"><N id="a1"></N></N></1y><N id="aG" X="3f" 15="2p: 28;"><1q>\'+7.C.1a.dJ+\'</1q><1v 1o="1d" 2m="4D" id="4D" X="3q"  /></N></1w><35><2g X="3h 4T">\'+7.C.1a.4X+\'</2g><1v 1o="2g" 2m="4I" X="3h" id="dL" 2T="\'+7.C.1a.63+\'" /></35>\',dM:3y()+\'<1w><1y id="hf" 5m="4R" 4A=""><N id="3M"><a 1N="#" X="4k">9z</a><a 1N="#">aB</a><a 1N="#">\'+7.C.1a.aH+\'</a></N><1v 1o="7k" id="5K" 2T="1" /><N X="3f" id="dQ"><1q>9z</1q><1v 1o="1d" id="69" X="3q"  /><1q>\'+7.C.1a.1d+\'</1q><1v 1o="1d" X="3q 6w" id="dO" /><1q><1v 1o="dN" id="4V"> \'+7.C.1a.aD+\'</1q></N><N X="3f" id="aC" 15="2p: 28;"><1q>aB</1q><1v 1o="1d" id="ay" X="3q" /><1q>\'+7.C.1a.1d+\'</1q><1v 1o="1d" X="3q 6w" id="fF" /></N><N X="3f" id="aG" 15="2p: 28;"><1q>\'+7.C.1a.aH+\'</1q><1v 1o="1d" X="3q" id="aI"  /><1q>\'+7.C.1a.1d+\'</1q><1v 1o="1d" X="3q 6w" id="fJ" /></N></1y></1w><35><2g X="3h 4T">\'+7.C.1a.4X+\'</2g><1v 1o="2g" X="3h" id="fy" 2T="\'+7.C.1a.63+\'" /></35>\',fG:3y()+"<1w><1q>"+7.C.1a.fD+\'</1q><1v 1o="1d" 2h="5" 2T="2" id="am" /><1q>\'+7.C.1a.fC+\'</1q><1v 1o="1d" 2h="5" 2T="3" id="f8" /></1w><35><2g X="3h 4T">\'+7.C.1a.4X+\'</2g><1v 1o="2g" 2m="4I" X="3h" id="fb" 2T="\'+7.C.1a.63+\'" /></35>\',f5:3y()+\'<1w><1y id="gP"><1q>\'+7.C.1a.fu+\'</1q><5t id="9A" 15="2r: 99%; 1C: hg;"></5t></1y></1w><35><2g X="3h 4T">\'+7.C.1a.4X+\'</2g><1v 1o="2g" X="3h" id="f0" 2T="\'+7.C.1a.63+\'" /></35>\'})},4J:B(m,i,g,n){y f=d("#9L");if(!f.11){7.$ff=f=d(\'<N id="9L" 15="2p: 28;"></N>\');d("1O").4W(7.$ff)}if(7.C.9K){f.1K().1i("1L",d.K(7.2j,7))}y j=d("#9y");if(!j.11){7.$fh=j=d(\'<N id="9y" 15="2p: 28;"><N id="9B">&hw;</N><5x id="7q"></5x><N id="7D"></N></N>\');d("1O").Z(7.$fh)}d("#9B").1i("1L",d.K(7.2j,7));7.5A=d.K(B(o){if(o.2n===7.2n.9T){7.2j();F E}},7);d(Q).3B(7.5A);7.$J.3B(7.5A);7.4u=E;if(i.3x("#")==0){7.4u=d(i);d("#7D").7n().Z(7.4u.U());7.4u.U("")}G{d("#7D").7n().Z(i)}j.V("#7q").U(m);if(1r d.fn.fd!=="1l"){j.fd({gm:"#7q"});j.V("#7q").T("9S","gs")}y l=d("#3M");if(l.11){y h=7;l.V("a").18(B(o,p){o++;d(p).1i("1L",B(r){r.2a();l.V("a").2e("4k");d(7).23("4k");d(".3f").1T();d("#3f"+o).1K();d("#5K").1e(o);if(h.4b()===E){y q=j.er();j.T("1Z-1W","-"+(q+10)/2+"2y")}})})}j.V(".4T").1i("1L",d.K(7.2j,7));if(7.C.4f===L){7.aQ=7.Q.1O.3H}if(7.4b()===E){j.T({2u:"7C",1W:"-aa",1t:"50%",2r:g+"2y",7G:"-"+(g+60)/2+"2y"}).1K();7.aO=d(Q.1O).T("aP");d(Q.1O).T("aP","7k")}G{j.T({2u:"7C",2r:"2x%",1C:"2x%",1W:"0",1t:"0",1Z:"0",5H:"gq"}).1K()}if(1r n==="B"){n()}if(7.4b()===E){2k(B(){y o=j.er();j.T({1W:"50%",1C:"3L",5H:"3L",7B:"-"+(o+10)/2+"2y"})},10)}},2j:B(){d("#9B").2H("1L",7.2j);d("#9y").4Q("jt",d.K(B(){y f=d("#7D");if(7.4u!==E){7.4u.U(f.U());7.4u=E}f.U("");if(7.C.9K){d("#9L").1T().2H("1L",7.2j)}d(Q).ej("3B",7.5A);7.$J.ej("3B",7.5A);7.1k();if(7.C.4f&&7.aQ){d(7.Q.1O).3H(7.aQ)}},7));if(7.4b()===E){d(Q.1O).T("aP",7.aO?7.aO:"dr")}F E},ah:B(f){d(".3f").1T();d("#3M").V("a").2e("4k").eq(f-1).23("4k");d("#3f"+f).1K()},fm:B(l){y h=l.1I.79;2K(y g=0,j;j=h[g];g++){7.fA(j)}},fA:B(f){7.bt(f,d.K(B(g){7.fp(f,g)},7))},bt:B(f,h){y g=1R ei();g.7E("i0",7.C.6g+"?2m="+f.2m+"&1o="+f.1o,L);g.il("1d/iq; kq=x-kw-kh");g.kS=B(i){if(7.eo==4&&7.9Q==3Z){d("#M-1X").dW();h(k9(7.k0))}G{if(7.eo==4&&7.9Q!=3Z){}}};g.dI()},fj:B(h,f){y g=1R ei();if("ge"in g){g.7E(h,f,L)}G{if(1r eY!="1l"){g=1R eY();g.7E(h,f)}G{g=26}}F g},fp:B(g,f){y h=7.fj("hx",f);if(!h){}G{h.fo=d.K(B(){if(h.9Q==3Z){d("#M-1X").1T();y l=f.3k("?");if(!l[0]){F E}7.1k();y i="";i=\'<1p id="1b-1u" 2q="\'+l[0]+\'" />\';if(7.C.4w){i="<p>"+i+"</p>"}7.1H("3z",i,E);y j=d(7.$J.V("1p#1b-1u"));if(j.11){j.24("id")}G{j=E}7.12();7.1f("3b",j,E);7.2j();7.3r()}G{}},7);h.hl=B(){};h.4I.hP=B(i){};h.f4("hI-hC",g.1o);h.f4("x-gI-gT","gW-he");h.dI(g)}},a0:B(h,f){7.2w={2S:E,2O:E,33:E,4P:E,a9:E,3L:E,1v:E};d.3S(7.2w,f);y g=d("#"+h);if(g.11&&g[0].Y==="gH"){7.2w.1v=g;7.el=d(g[0].1y)}G{7.el=g}7.ek=7.el.16("4A");if(7.2w.3L){d(7.2w.1v).6n(d.K(B(i){7.el.aM(B(j){F E});7.9V(i)},7))}G{if(7.2w.a9){d("#"+7.2w.a9).1L(d.K(7.9V,7))}}},9V:B(f){d("#M-1X").dW();7.ey(7.4h,7.dE())},dE:B(){7.id="f"+39.de(39.dD()*dy);y g=7.Q.3O("N");y f=\'<1n 15="2p:28" id="\'+7.id+\'" 2m="\'+7.id+\'"></1n>\';g.4y=f;d(g).71("1O");if(7.2w.4P){7.2w.4P()}d("#"+7.id).ds(d.K(7.ef,7));F 7.id},ey:B(j,i){if(7.2w.1v){y l="hu"+7.id,g="hQ"+7.id;7.1y=d(\'<1y  4A="\'+7.2w.2S+\'" 5m="6k" 1I="\'+i+\'" 2m="\'+l+\'" id="\'+l+\'" 70="6P/1y-1g" />\');if(7.C.36!==E&&1r 7.C.36==="2I"){d.18(7.C.36,d.K(B(n,f){if(f!=26&&f.2W().3x("#")===0){f=d(f).1e()}y o=d("<1v/>",{1o:"7k",2m:n,2T:f});d(7.1y).Z(o)},7))}y h=7.2w.1v;y m=d(h).4K();d(h).16("id",g).34(m).71(7.1y);d(7.1y).T("2u","6j").T("1W","-aa").T("1t","-aa").71("1O");7.1y.aM()}G{j.16("1I",i).16("5m","6k").16("70","6P/1y-1g").16("4A",7.2w.2S);7.4h.aM()}},ef:B(){y j=d("#"+7.id)[0],l;if(j.eb){l=j.eb}G{if(j.ac){l=j.ac.Q}G{l=2Z.g8[7.id].Q}}if(7.2w.2O){d("#M-1X").1T();if(1r l!=="1l"){y h=l.1O.4y;y g=h.1Q(/\\{(.|\\n)*\\}/)[0];g=g.I(/^\\[/,"");g=g.I(/\\]$/,"");y f=d.6i(g);if(1r f.33=="1l"){7.2w.2O(f)}G{7.2w.33(7,f);7.2j()}}G{7.2j();gj("ev g2!")}}7.el.16("4A",7.ek);7.el.16("1I","")},8g:B(g,f){7.3o=d.3S({2S:E,2O:E,33:E,jR:E,36:E,1d:7.C.1a.es,ea:7.C.1a.e7},f);if(2Z.7c===1l){F E}7.86=d(\'<N X="jz"></N>\');7.3J=d(\'<N X="hR">\'+7.3o.1d+"</N>");7.eM=d(\'<N X="jw">\'+7.3o.ea+"</N>");7.86.Z(7.3J);d(g).34(7.86);d(g).34(7.eM);7.3J.1i("kl",d.K(B(){F 7.dn()},7));7.3J.1i("kJ",d.K(B(){F 7.dm()},7));7.3J.1S(0).kF=d.K(B(h){h.2a();7.3J.2e("8G").23("5r");7.eB(h.80.79[0])},7)},eB:B(g){y i=dZ.kT.dh();if(i.4I){i.4I.kO("1X",d.K(7.dT,7),E)}y h=B(){F i};y f=1R 7c();if(7.3o.36!==E&&1r 7.3o.36==="2I"){d.18(7.3o.36,d.K(B(l,j){if(j!=26&&j.2W().3x("#")===0){j=d(j).1e()}f.Z(l,j)},7))}f.Z("2U",g);d.8z({2S:7.3o.2S,dA:"U",1g:f,dh:h,dg:E,6s:E,df:E,1o:"6k",2O:d.K(B(l){l=l.I(/^\\[/,"");l=l.I(/\\]$/,"");y j=d.6i(l);if(1r j.33=="1l"){7.3o.2O(j)}G{7.3o.33(7,j);7.3o.2O(E)}},7)})},dn:B(){7.3J.23("8G");F E},dm:B(){7.3J.2e("8G");F E},dT:B(g,h){y f=g.dY?7O(g.dY/g.ij*2x,10):g;7.3J.1d("ik "+f+"% "+(h||""))},4b:B(){F/(iF|iC|iB|iz)/.3p(96.98)},7K:B(f){if(1r(f)==="1l"){F 0}F 7O(f.I("2y",""),10)},5h:B(f){F d("<N>").Z(d(f).eq(0).4K()).U()},f6:B(f){F ia.3X.2W.3t(f)=="[2I 3y]"},8Y:B(f){f=f.I(/&#7r;|<br>|<br\\/>|&2i;/gi,"");f=f.I(/\\s/g,"");f=f.I(/^<p>[^\\W\\w\\D\\d]*?<\\/p>$/i,"");F f==""},1J:B(g){y h=96.98.30();y f=/(8b)[ \\/]([\\w.]+)/.1M(h)||/(3K)[ \\/]([\\w.]+)/.1M(h)||/(7y)(?:.*7N|)[ \\/]([\\w.]+)/.1M(h)||/(3a) ([\\w.]+)/.1M(h)||h.3x("ji")<0&&/(3Q)(?:.*? jr:([\\w.]+)|)/.1M(h)||[];if(g=="7N"){F f[2]}if(g=="3K"){F(f[1]=="8b"||f[1]=="3K")}F f[1]==g},88:B(){if(7.1J("3a")&&7O(7.1J("7N"),10)<9){F L}F E},b4:B(g){y f=g.iP(L);y h=7.Q.3O("N");h.5d(f);F h.4y},8e:B(){y f=7.$J[0];y h=7.Q.b7();y g;2E((g=f.8v)){h.5d(g)}F h},7o:B(f){if(!f){F E}if(7.C.1n){F f}if(d(f).83("N.31").11==0||d(f).3c("31")){F E}G{F f}},6d:B(f){y g=7.3F(),h=7.2D();F g&&g.Y===f?g:h&&h.Y===f?h:E},bH:B(){y g=7.1V();y i=7.bE(g);y h=d.2o(d(g).1d()).I(/\\n\\r\\n/g,"");y f=h.11;if(i==f){F L}G{F E}},7z:B(){y f,g=7.1F();if(g&&g.44&&g.44>0){f=g.2R(0).4H}if(!f){F E}if(7.C.1n){if(7.bK().bx()){F!7.$J.is(f)}G{F L}}F d(f).2A("N.31").11!=0},3C:B(g,f){if(d(g).16(f)==""){d(g).24(f)}},aS:B(h,g){y f=26;2E((f=h.3x(g))!==-1){h.7H(f,1)}F h}};c.3X.5n.3X=c.3X;d.4a.fn.a3=B(t,q,j,o){y p=/(^|&6e;|\\s)(bP\\..+?\\..+?)(\\s|&gt;|$)/g,m=/(^|&6e;|\\s)(((6B?|8S):\\/\\/|6h:).+?)(\\s|&gt;|$)/g,f=/(6B?:\\/\\/.*\\.(?:cI|io|cN|cF))/gi,s=/^.*(ks.be\\/|v\\/|u\\/\\w\\/|3w\\/|ko\\?v=|\\&v=)([^#\\&\\?]*).*/;y r=(7.$J?7.$J.1S(0):7).9e,h=r.11;2E(h--){y g=r[h];if(g.3s===3){y l=g.6f;if(o&&l&&l.1Q(s)){l=l.I(s,\'<1n 2r="kD" 1C="kH" 2q="//bP.jN.jG/3w/$2" co="0" jQ></1n>\');d(g).22(l).1m()}G{if(j&&l&&l.1Q(f)){l=l.I(f,\'<1p 2q="$1">\');d(g).22(l).1m()}G{if(q&&l&&(l.1Q(p)||l.1Q(m))){l=l.I(/&/g,"&8t;").I(/</g,"&6e;").I(/>/g,"&gt;").I(p,\'$1<a 1N="\'+t+\'$2">$2</a>$3\').I(m,\'$1<a 1N="$2">$2</a>$5\');d(g).22(l).1m()}}}}G{if(g.3s===1&&!/^(a|2g|5t)$/i.3p(g.Y)){d.4a.fn.a3.3t(g,t,q,j,o)}}}}})(dZ);',62,1297,'|||||||this|||||||||||||||||||||||||||var|||function|opts||false|return|else||replace|editor|proxy|true|redactor|div|span||document|title||css|html|find||class|tagName|append||length|sync|||style|attr||each|toolbar|curLang|image|func|text|val|callback|data|source|on|table|selectionRestore|undefined|remove|iframe|type|img|label|typeof|focus|left|marker|input|section|bufferSet|form|linebreaks|td|selectionSave|height|li|box|getSelection|contents|execCommand|target|browser|show|click|exec|href|body|parent|match|new|get|hide|replaceWith|getBlock|top|progress|invisibleSpace|margin||push|after|addClass|removeAttr|ul|null||none||preventDefault|air|selection|pre|removeClass|frame|button|size|nbsp|modalClose|setTimeout|script|name|keyCode|trim|display|src|width|blockquote|buttonGet|position|ol|uploadOptions|100|px|link|closest|getBlocks|getRange|getCurrent|while|RegExp|LI|off|object|rangy|for|tr|thead|video|success|dropdown|verified|getRangeAt|url|value|file|rel|toString|contenteditable|fullpage|window|toLowerCase|redactor_editor|insertNode|error|before|footer|uploadFields||offset|Math|msie|imageUpload|hasClass|italic|className|redactor_tab|buttons|redactor_modal_btn|bold|option|split|substr|selectionStart|font|draguploadOptions|test|redactor_input|observeImages|nodeType|call|php|current_tr|embed|indexOf|String|inserthtml|tag|keyup|removeEmptyAttr|right|strong|getParent|inArray|scrollTop|formatBlocks|dropareabox|webkit|auto|redactor_tabs|content|createElement|placeholder|mozilla|shortcutsLoad|extend|shortcutsLoadFormat|shiftKey|toolbarFixed|search|prototype|visual|200||buttonActive|buffer|audio|rangeCount|redactor_file||deleted|||Redactor|isMobile|savedSel|charAt|parentNode|autoresize|alignmentTags|element|emptyHtml|imageEditter|redactor_tabs_act|redactor_placeholder|direction|Insert|textareamode|orderedlist|keydown|float|unorderedlist|round|modalcontent|dir|paragraphy|BLOCKQUOTE|innerHTML|collapsed|action|inlineMethods|range|redactor_file_link|removeAllRanges|PRE|tbody|startContainer|upload|modalInit|clone|formatting|indent|filelink|selectall|start|fadeOut|post|bar|redactor_btn_modal_close|select|redactor_link_blank|prepend|cancel|createRange|addRange||||||outdent|cleanGetTabs|getNodes|not|redactor_act|observeStart|autosave|dropact|appendChild|formatBlock|param|10px|outerHtml|justify|code|imageResizeHide|_blank|method|init|buttonBuild|redactorfolder|join|drop|allowedTags|textarea|underline|insert_link_node|unlink|header|buttonSeparator|modified|hdlModalClose|Delete|Add|Header|horizontalrule|enter|tabindex|minHeight|shortcuts|isFunction|redactor_tab_selected|cleanlevel|cleanStripTags|next|buttonActiveObserver|endContainer|linkProtocol|fileUpload|fontSize|color|resize|imageGetJson|getElement|selectionSet|line|deniedTags||phpTags|cleanRemoveSpaces|insert|alignmentSet|||selectionEnd|rebuffer|redactor_link_url|tagblock|insertunorderedlist|break|currentOrParentIs|lt|nodeValue|s3|mailto|parseJSON|absolute|POST|alignleft|ARTICLE|change|alignright|activeButtonsAdd|activeButtons|7px|contentType|ASIDE|aligncenter|insertorderedlist|redactor_link_text|selectNodeContents|setStart|alignment|template|https|javascript|setEnd|indentValue|FOOTER|redactor_btn_|SECTION|ADDRESS|selectionSetMarker|collapse|nodeTestBlocks|children|convertImageLinks|folder|multipart|set|autosaveInterval|ENTER|BACKSPACE|which|checked|insertAfter|prop|buildCodearea|mouseup|enctype|appendTo|||||||dropdownHideAll|files|airBindMousemoveHide|first|FormData|prev|one|separator|toolbarFixedBox|11px|DIV|insertHtmlAdvanced|hidden|imageInsert|HEADER|empty|isParentRedactor|del|redactor_modal_header|x200b|pasteInsert|saveScroll|cleanConvertInlineTags|align|cleanParagraphy|background|opera|isFocused|placeTag|marginTop|fixed|redactor_modal_inner|open|insertAfterLastElement|marginLeft|splice|strike|paste|normalize|clipboardUpload|insertHtml|version|parseInt|head|linkAnchor|alignmentCenter|buildOptions|insertLineBreak|iframeAddCss|alignmentRight|address|linkEmail|alignmentJustify|airShow|dataTransfer|current_td|iframeLoad|parents|cleannewLevel|alignmentLeft|droparea|redactor_air|oldIE|buildAfter|cleanRemoveEmptyTags|chrome|inlineEachNodes|buildBindKeyboard|extractContent|tfoot|draguploadInit|pasteHTML|toggle|blockLevelElements|setFullpageOnInit|imageUploadError|tableAddColumn|toolbarExternal|altKey|z0|toolbarObserveScroll|parseHTML|SPAN|amp|fileCallback|firstChild|uuid|http|toolbarFixedTarget|ajax|indentingOutdent|selectionRemoveMarkers|indentingStart|cloneRange|italicTag|indentingIndent|hover|cleanEncodeEntities|cleanSavePreCode|iframePage|pasteClipboardMozilla|insideOutdent|getTextNodesIn|th|templateVars|selectionElement|iframeDoc|meta|ftp|clipboardUploadUrl|cleanEmpty|cleanConverters|cleanConvertProtected|boldTag|isEmpty|rTestBlock|||redactor_btn|merge|redactor_button_disabled|syncClean|navigator|tableObserver|userAgent||cleanTag|cleanFinish|tableDeleteHead|buttonInactive|childNodes|redactor_btn_right|case|filter|selnodes|catch|try|textContent|tagTestBlock|link_insert|convertDivs|activeButtonsStates|getRangeSelectedNodes|tableAddRow|focusSet|DOWN|redactor_filename|lineHeight|zIndex|insert_row_below|redactor_modal|URL|redactor_insert_video_area|redactor_modal_close|Table|Row|redactor_file_alt|insert_column_left|padding|align_justify|rBlockTest|resizer|modalOverlay|redactor_modal_overlay|Column|insert_row_above|insert_table|ownLine|status|alt|cursor|ESC|imageCallback|uploadSubmit|sourceHeight|contOwnLine|save|redactor_form_image_align|uploadInit|redactor_image_box|filename|formatLinkify|delete_table|striped|choose|dnbImageTypes|drag|trigger|2000px|pageY|contentWindow|pageX|align_left|plugins|insert_column_right|modalSetTab|DELETE|delete|add_head|backcolor|redactor_table_rows|delete_head|delete_column|delete_row|iframeAppend|mousedown|RedactorPlugins|fontcolor|sourceOld|FIGCAPTION|imageRemove|createTextNode|redactor_link_mailto|buildEnable|align_right|Email|redactor_tab2|link_new_tab|ctrlKey|editter|redactor_tab3|anchor|redactor_link_anchor|align_center|convertLinks|convertVideoLinks|submit|buildEventKeydownInsertLineBreak|modalSaveBodyOveflow|overflow|saveModalScroll|quote|removeFromArrayByValue|area|fieldset|map|header5|header4|header2|header3|header1|Video|DL|formatEmpty|getFragmentHtml|formatblock|DT|createDocumentFragment|center|List|Color|OUTPUT|formatQuote|BR||H3|H2|H1|unwrap|H4|inlineUnwrapSpan|DD|inlineSetMethods|H6|H5|Head|cleanlineAfter||Edit|s3executeOnSignedUrl|the|to|newLevel|equals|lang|quot|langs|cleanUnverified|Align|Code|getCaretOffset|Left|cleanlineBefore|isEndOfElement|Right|Image|getCaretOffsetRange|Link|cleanHtml|paragraph|nofollow|www|TD|metaKey|innerWidth|airEnable|toolbar_fixed_box|TAB|toolbarFixedTopOffset|visibility|airBindHide|LEFT_WIN|originalEvent|returnValue|buildEventClipboardUpload|cleanup|clipboardData|dropdownHide|buildEventKeydown|clipboardFilePaste|items|tabFocus|8203|placeholderFocus|placeholderRemove|placeholderRemoveFromCode|buildPlugins|iframeStart|iframeCreate|clearInterval|write|documentElement|substring|setInterval|buttonsAdd|formattingTags|frameborder|buttonsCustom|buttonSource|buildEventKeyup|toolbarBuild|airButtons|buildEventPaste|dropdownShow|inserthorizontalrule|close|linkNofollow|tidyHtml|formattingPre|buildStart|buildContent|buildMobile|mobile|gif|getCodeIframe|double|png|cleanReplacer|buffer_|cleanReConvertProtected|placeholderStart|jpeg|setCodeIframe|setEditor|buildFromTextarea|buildFromElement|buttonInactiveVisual|blurCallback|blur|focusCallback|buttonActiveVisual|buildEventDrop|redactor_dropdown|redactor_dropdown_box_|dropdownBuild|redactor_btn_html|dragUpload|redactor_dropdown_link|wym|buildAddClasses|link_edit|buttonActiveToggle|initToolbar|redactor_editor_wym|buttonInactiveAll|removeEmptyTags|transparent||floor|processData|cache|xhr|unshift|modalTemplatesInit|getSelectedNodes||draguploadOndragleave|draguploadOndrag|modal_image_edit|modal_file|nextNode|visible|load||imageThumbClick|8px|000|backgroundColor|99999|imageCallbackLink|dataType|nextSibling|getSelectionText|random|uploadFrame|image_position|formatChangeTag|selectionWrap|send|image_web_link|selectionRemove|redactor_upload_btn|modal_link|checkbox|redactor_link_url_text|observeTables|redactor_tab1|endOffset|setCaret|uploadProgress|_delete|redactor_image_delete_btn|fadeIn|redactorSaveBtn|loaded|jQuery|modal_image|apply|selectionCreateMarker|fff|1px|mousemove|linkInsert|or_choose|fileShow|fileUploadError|atext|contentDocument|linkProcess|relative|imageResizeControls|uploadLoaded|inside|imageResize|XMLHttpRequest|unbind|element_action||||readyState|imageSave||outerHeight|drop_file_here|imageShow|isEmptyObject|Upload|location|self|uploadForm|tableDeleteColumn|tableAddHead|draguploadUpload|tableAddRowAbove|tableDeleteRow|tableDeleteTable|5px|cloneContents|tableShow|tableInsert|tableAddRowBelow|tableAddColumnLeft|videoShow|dropalternative|videoInsert|linkShow|0px|opacity|tableAddColumnRight|imageEdit|18px|edit|pop|u0000|deleteContents|XDomainRequest|internal|redactor_insert_video_btn|pastePlainText|replaceLineBreak|pasteClean|setRequestHeader|modal_video|isString|pasteClipboardUploadMozilla|redactor_table_columns|innerText|pastePre|redactor_insert_table_btn|setStartAfter|draggable|caretPositionFromPoint|overlay|createTextRange|modal|caretRangeFromPoint|s3createCORSRequest|moveToPoint|clientY|s3handleFileSelect||onload|s3uploadToS3|last|clientX|insertNodeToCaretPositionFromPoint|pasteClipboardUpload|video_html_code|BODY|bufferRedo|HTML|redactor_insert_link_btn|article|s3uploadFile|bufferUndo|columns|rows|aside|redactor_link_mailto_text|modal_table|focusEnd|clipboard|redactor_link_anchor_text|sourceWidth|defaultView|outline|dropdowns|block|ownerDocument|Embed|dashed|rgba|removeFormat|redactor_image_edit_src|Open|toUpperCase|Columns|pointer|Title|380|tab|failed|charCodeAt|None|Position|imageDelete|LEFT|frames|Name|optional|TH|dragstart|Underline|withCredentials|isArray|removeChild|Web||alert|Alignment|stylesheet|handle|Text|3px|9px|300px|META|move||web|13px|Rule|Deleted|Horizontal|CTRL|Justify|inline|readAsDataURL|TEXTAREA|Rows|Choose|redactor_box|INPUT|amz|redactorInsertImageForm|separator_drop3|redactor_|Or|enableObjectResizing|separator_drop1|redactorInsertVideoForm|separator_drop2|min|redactorUploadFileForm|acl|Download|blank|public|getEditor|about|getBox|getToolbar|||||||getIframe|syncBefore|syncAfter|destroy|Callback|removeData|getObject|read|redactorInsertLinkForm|160px|Drop|redactor_format_h1|bottom|redactor_format_pre|onerror|FileReader|getAsFile|4px|undo|redactor_format_blockquote||File|nw|redactorUploadForm|redo|times|PUT|download|redactor_format_h2|border|strikethrough|Type|redactor_format_h5|Center|bull|enableInlineTableEditing|here|Content|redactor_format_h4|536|solid|Chrome|redactor_format_h3|slow|onprogress|redactorUploadFile|redactor_dropareabox|details|figcaption|menu|summary|ns|figure|nav|math|GET|legend|hgroup|hasOwnProperty|frameset|redactor_separator|sub|sup|ltr|applet|Object|weight|noscript||result||pasteAfter|colgroup|col|total|Loading|overrideMimeType|selectionAll||jpg|saveSelection|plain|removeMarkers||restoreSelection|detach|extractContents|u200B|unselectable|comment|Android|caption|BlackBerry|iPod|u200D|uFEFF|iPhone|concat|small|VERSION|blockRemoveAttr|blockSetAttr|blockRemoveStyle|blockSetStyle|setEndAfter|use|cloneNode|offsetNode|startOffset|strict|blockRemoveClass|blockSetClass|insertText|attributes|inlineFormat|inlineRemoveFormat|inlineSetAttr|inlineRemoveAttr|inlineRemoveClass|inlineSetClass|inlineRemoveStyle|inlineSetStyle|duplicate|JustifyFull|guid|docs|slice|sid|arguments|string|fake|cite|such|No|Array|compatible|JustifyRight|EndToEnd|JustifyCenter|setEndPoint|insertDoubleLineBreak|JustifyLeft|MsoListParagraphCxSpLast|MsoListParagraphCxSpFirst|rv|pasteBefore|fast|replaced|Anchor|redactor_dropalternative|redactor_toolbar|redactor_toolbar_|redactor_droparea|1000|escape|encodeURIComponent|Bold|500|redactor_air_|com|460|host|UL|600|1005|Quote|youtube|scroll|xn|allowfullscreen|preview|Save|Cancel|Indent|Outdent|Above|Below|superscript|subscript|responseText|Ordered|Unordered|innerHeight|thumb|Italic|getJSON|redactor_image_box_select|Font|decodeURIComponent|Back|610|Normal|focusNode|buttonAddFirst|buttonAddAfter|buttonAddBefore|defined|buttonAdd|buttonSetLeft|getSelectionHtml|dragover|buttonRemoveSeparatorBefore|buttonSetRight|watch|buttonRemove|charset|nodeName|youtu|OL|default|isCollapsed|user|hasChildNodes|commonAncestorContainer|switch|buttonAddSeparatorBefore|buttonRemoveSeparatorAfter|Formatting|560|Unlink|ondrop|redactor_dropdown_|315|collapseToStart|dragleave|redactor_separator_drop|buttonAddSeparatorAfter|stopPropagation|buttonAddSeparator|addEventListener|300|buttonChangeIcon|buttonRemoveIcon|onreadystatechange|ajaxSettings|cellIndex'.split('|'),0,{}))
\ No newline at end of file
+(function(c){var a=0;"use strict";var d=function(e){this[0]=e.startOffset;this[1]=e.endOffset;this.range=e;return this;};d.prototype.equals=function(){return this[0]===this[1];};c.fn.redactor=function(f){var g=[];var e=Array.prototype.slice.call(arguments,1);if(typeof f==="string"){this.each(function(){var i=c.data(this,"redactor");if(typeof i!=="undefined"&&c.isFunction(i[f])){var h=i[f].apply(i,e);if(h!==undefined&&h!==i){g.push(h);}}else{return c.error('No such method "'+f+'" for Redactor');}});}else{this.each(function(){if(!c.data(this,"redactor")){c.data(this,"redactor",b(this,f));}});}if(g.length===0){return this;}else{if(g.length===1){return g[0];}else{return g;}}};function b(f,e){return new b.prototype.init(f,e);}c.Redactor=b;c.Redactor.VERSION="9.1.6";c.Redactor.opts={rangy:false,iframe:false,fullpage:false,css:false,lang:"en",direction:"ltr",placeholder:false,wym:false,mobile:true,cleanup:true,tidyHtml:true,pastePlainText:false,removeEmptyTags:true,templateVars:false,xhtml:false,visual:true,focus:false,tabindex:false,autoresize:true,minHeight:false,shortcuts:true,autosave:false,autosaveInterval:60,plugins:false,linkAnchor:true,linkEmail:true,linkProtocol:"http://",linkNofollow:false,linkSize:50,imageFloatMargin:"10px",imageGetJson:false,imageUpload:false,imageUploadParam:"file",fileUpload:false,fileUploadParam:"file",clipboardUpload:true,clipboardUploadUrl:false,dragUpload:true,dnbImageTypes:["image/png","image/jpeg","image/gif"],s3:false,uploadFields:false,observeImages:true,observeLinks:true,modalOverlay:true,tabSpaces:false,tabFocus:true,air:false,airButtons:["formatting","|","bold","italic","deleted","|","unorderedlist","orderedlist","outdent","indent"],toolbar:true,toolbarFixed:false,toolbarFixedTarget:document,toolbarFixedTopOffset:0,toolbarFixedBox:false,toolbarExternal:false,buttonSource:true,buttonSeparator:'<li class="redactor_separator"></li>',buttonsCustom:{},buttonsAdd:[],buttons:["html","|","formatting","|","bold","italic","deleted","|","unorderedlist","orderedlist","outdent","indent","|","image","video","file","table","link","|","alignment","|","horizontalrule"],activeButtons:["deleted","italic","bold","underline","unorderedlist","orderedlist","alignleft","aligncenter","alignright","justify","table"],activeButtonsStates:{b:"bold",strong:"bold",i:"italic",em:"italic",del:"deleted",strike:"deleted",ul:"unorderedlist",ol:"orderedlist",u:"underline",tr:"table",td:"table",table:"table"},activeButtonsAdd:false,formattingTags:["p","blockquote","pre","h1","h2","h3","h4","h5","h6"],linebreaks:false,paragraphy:true,convertDivs:true,convertLinks:true,convertImageLinks:false,convertVideoLinks:false,formattingPre:false,phpTags:false,allowedTags:false,deniedTags:["html","head","link","body","meta","script","style","applet"],boldTag:"strong",italicTag:"em",indentValue:20,buffer:[],rebuffer:[],textareamode:false,emptyHtml:"<p>&#x200b;</p>",invisibleSpace:"&#x200b;",rBlockTest:/^(P|H[1-6]|LI|ADDRESS|SECTION|HEADER|FOOTER|ASIDE|ARTICLE)$/i,alignmentTags:["P","H1","H2","H3","H4","H5","H6","DD","DL","DT","DIV","TD","BLOCKQUOTE","OUTPUT","FIGCAPTION","ADDRESS","SECTION","HEADER","FOOTER","ASIDE","ARTICLE"],ownLine:["area","body","head","hr","i?frame","link","meta","noscript","style","script","table","tbody","thead","tfoot"],contOwnLine:["li","dt","dt","h[1-6]","option","script"],newLevel:["blockquote","div","dl","fieldset","form","frameset","map","ol","p","pre","select","td","th","tr","ul"],blockLevelElements:["P","H1","H2","H3","H4","H5","H6","DD","DL","DT","DIV","LI","BLOCKQUOTE","OUTPUT","FIGCAPTION","PRE","ADDRESS","SECTION","HEADER","FOOTER","ASIDE","ARTICLE","TD"],langs:{en:{html:"HTML",video:"Insert Video",image:"Insert Image",table:"Table",link:"Link",link_insert:"Insert link",link_edit:"Edit link",unlink:"Unlink",formatting:"Formatting",paragraph:"Normal text",quote:"Quote",code:"Code",header1:"Header 1",header2:"Header 2",header3:"Header 3",header4:"Header 4",header5:"Header 5",bold:"Bold",italic:"Italic",fontcolor:"Font Color",backcolor:"Back Color",unorderedlist:"Unordered List",orderedlist:"Ordered List",outdent:"Outdent",indent:"Indent",cancel:"Cancel",insert:"Insert",save:"Save",_delete:"Delete",insert_table:"Insert Table",insert_row_above:"Add Row Above",insert_row_below:"Add Row Below",insert_column_left:"Add Column Left",insert_column_right:"Add Column Right",delete_column:"Delete Column",delete_row:"Delete Row",delete_table:"Delete Table",rows:"Rows",columns:"Columns",add_head:"Add Head",delete_head:"Delete Head",title:"Title",image_position:"Position",none:"None",left:"Left",right:"Right",image_web_link:"Image Web Link",text:"Text",mailto:"Email",web:"URL",video_html_code:"Video Embed Code",file:"Insert File",upload:"Upload",download:"Download",choose:"Choose",or_choose:"Or choose",drop_file_here:"Drop file here",align_left:"Align text to the left",align_center:"Center text",align_right:"Align text to the right",align_justify:"Justify text",horizontalrule:"Insert Horizontal Rule",deleted:"Deleted",anchor:"Anchor",link_new_tab:"Open link in new tab",underline:"Underline",alignment:"Alignment",filename:"Name (optional)",edit:"Edit"}}};b.fn=c.Redactor.prototype={keyCode:{BACKSPACE:8,DELETE:46,DOWN:40,ENTER:13,ESC:27,TAB:9,CTRL:17,META:91,LEFT:37,LEFT_WIN:91},init:function(f,e){this.rtePaste=false;this.$element=this.$source=c(f);this.uuid=a++;var g=c.extend(true,{},c.Redactor.opts);this.opts=c.extend({},g,this.$element.data(),e);this.start=true;this.dropdowns=[];this.sourceHeight=this.$source.css("height");this.sourceWidth=this.$source.css("width");if(this.opts.fullpage){this.opts.iframe=true;}if(this.opts.linebreaks){this.opts.paragraphy=false;}if(this.opts.paragraphy){this.opts.linebreaks=false;}if(this.opts.toolbarFixedBox){this.opts.toolbarFixed=true;}this.document=document;this.window=window;this.savedSel=false;this.cleanlineBefore=new RegExp("^<(/?"+this.opts.ownLine.join("|/?")+"|"+this.opts.contOwnLine.join("|")+")[ >]");this.cleanlineAfter=new RegExp("^<(br|/?"+this.opts.ownLine.join("|/?")+"|/"+this.opts.contOwnLine.join("|/")+")[ >]");this.cleannewLevel=new RegExp("^</?("+this.opts.newLevel.join("|")+")[ >]");this.rTestBlock=new RegExp("^("+this.opts.blockLevelElements.join("|")+")$","i");if(this.opts.linebreaks===false){if(this.opts.allowedTags!==false&&c.inArray("p",this.opts.allowedTags)==="-1"){this.opts.allowedTags.push("p");}if(this.opts.deniedTags!==false){var h=c.inArray("p",this.opts.deniedTags);if(h!=="-1"){this.opts.deniedTags.splice(h,h);}}}if(this.browser("msie")||this.browser("opera")){this.opts.buttons=this.removeFromArrayByValue(this.opts.buttons,"horizontalrule");}this.opts.curLang=this.opts.langs[this.opts.lang];this.buildStart();},toolbarInit:function(e){return{html:{title:e.html,func:"toggle"},formatting:{title:e.formatting,func:"show",dropdown:{p:{title:e.paragraph,func:"formatBlocks"},blockquote:{title:e.quote,func:"formatQuote",className:"redactor_format_blockquote"},pre:{title:e.code,func:"formatBlocks",className:"redactor_format_pre"},h1:{title:e.header1,func:"formatBlocks",className:"redactor_format_h1"},h2:{title:e.header2,func:"formatBlocks",className:"redactor_format_h2"},h3:{title:e.header3,func:"formatBlocks",className:"redactor_format_h3"},h4:{title:e.header4,func:"formatBlocks",className:"redactor_format_h4"},h5:{title:e.header5,func:"formatBlocks",className:"redactor_format_h5"}}},bold:{title:e.bold,exec:"bold"},italic:{title:e.italic,exec:"italic"},deleted:{title:e.deleted,exec:"strikethrough"},underline:{title:e.underline,exec:"underline"},unorderedlist:{title:"&bull; "+e.unorderedlist,exec:"insertunorderedlist"},orderedlist:{title:"1. "+e.orderedlist,exec:"insertorderedlist"},outdent:{title:"< "+e.outdent,func:"indentingOutdent"},indent:{title:"> "+e.indent,func:"indentingIndent"},image:{title:e.image,func:"imageShow"},video:{title:e.video,func:"videoShow"},file:{title:e.file,func:"fileShow"},table:{title:e.table,func:"show",dropdown:{insert_table:{title:e.insert_table,func:"tableShow"},separator_drop1:{name:"separator"},insert_row_above:{title:e.insert_row_above,func:"tableAddRowAbove"},insert_row_below:{title:e.insert_row_below,func:"tableAddRowBelow"},insert_column_left:{title:e.insert_column_left,func:"tableAddColumnLeft"},insert_column_right:{title:e.insert_column_right,func:"tableAddColumnRight"},separator_drop2:{name:"separator"},add_head:{title:e.add_head,func:"tableAddHead"},delete_head:{title:e.delete_head,func:"tableDeleteHead"},separator_drop3:{name:"separator"},delete_column:{title:e.delete_column,func:"tableDeleteColumn"},delete_row:{title:e.delete_row,func:"tableDeleteRow"},delete_table:{title:e.delete_table,func:"tableDeleteTable"}}},link:{title:e.link,func:"show",dropdown:{link:{title:e.link_insert,func:"linkShow"},unlink:{title:e.unlink,exec:"unlink"}}},fontcolor:{title:e.fontcolor,func:"show"},backcolor:{title:e.backcolor,func:"show"},alignment:{title:e.alignment,func:"show",dropdown:{alignleft:{title:e.align_left,func:"alignmentLeft"},aligncenter:{title:e.align_center,func:"alignmentCenter"},alignright:{title:e.align_right,func:"alignmentRight"},justify:{title:e.align_justify,func:"alignmentJustify"}}},alignleft:{title:e.align_left,func:"alignmentLeft"},aligncenter:{title:e.align_center,func:"alignmentCenter"},alignright:{title:e.align_right,func:"alignmentRight"},justify:{title:e.align_justify,func:"alignmentJustify"},horizontalrule:{exec:"inserthorizontalrule",title:e.horizontalrule}};},callback:function(e,f,g){var h=this.opts[e+"Callback"];if(c.isFunction(h)){if(f===false){return h.call(this,g);}else{return h.call(this,f,g);}}else{return g;}},destroy:function(){clearInterval(this.autosaveInterval);c(window).off(".redactor");this.$source.off("redactor-textarea");this.$element.off(".redactor").removeData("redactor");var f=this.get();if(this.opts.textareamode){this.$box.after(this.$source);this.$box.remove();this.$source.val(f).show();}else{var e=this.$editor;if(this.opts.iframe){e=this.$element;}this.$box.after(e);this.$box.remove();e.removeClass("redactor_editor").removeClass("redactor_editor_wym").removeAttr("contenteditable").html(f).show();}if(this.opts.air){c("#redactor_air_"+this.uuid).remove();}},getObject:function(){return c.extend({},this);},getEditor:function(){return this.$editor;},getBox:function(){return this.$box;},getIframe:function(){return(this.opts.iframe)?this.$frame:false;},getToolbar:function(){return this.$toolbar;},get:function(){return this.$source.val();},getCodeIframe:function(){this.$editor.removeAttr("contenteditable").removeAttr("dir");var e=this.outerHtml(this.$frame.contents().children());this.$editor.attr({contenteditable:true,dir:this.opts.direction});return e;},set:function(e,f,g){e=e.toString();if(this.opts.fullpage){this.setCodeIframe(e);}else{this.setEditor(e,f);}if(g!==false){this.placeholderRemove();}},setEditor:function(e,f){if(f!==false){e=this.cleanSavePreCode(e);e=this.cleanStripTags(e);e=this.cleanConvertProtected(e);e=this.cleanConvertInlineTags(e);if(this.opts.linebreaks===false){e=this.cleanConverters(e);}else{e=e.replace(/<p(.*?)>([\w\W]*?)<\/p>/gi,"$2<br>");}}e=this.cleanEmpty(e);this.$editor.html(e);this.setNonEditable();this.setSpansVerified();this.sync();},setCodeIframe:function(e){var f=this.iframePage();this.$frame[0].src="about:blank";e=this.cleanConvertProtected(e);e=this.cleanConvertInlineTags(e);e=this.cleanRemoveSpaces(e);f.open();f.write(e);f.close();if(this.opts.fullpage){this.$editor=this.$frame.contents().find("body").attr({contenteditable:true,dir:this.opts.direction});}this.setNonEditable();this.setSpansVerified();this.sync();},setFullpageOnInit:function(e){e=this.cleanSavePreCode(e,true);e=this.cleanConverters(e);e=this.cleanEmpty(e);this.$editor.html(e);this.setNonEditable();this.setSpansVerified();this.sync();},setSpansVerified:function(){var f=this.$editor.find("span");var e="inline";c.each(f,function(){var g=this.outerHTML;var i=new RegExp("<"+this.tagName,"i");var h=g.replace(i,"<"+e);i=new RegExp("</"+this.tagName,"i");h=h.replace(i,"</"+e);c(this).replaceWith(h);});},setSpansVerifiedHtml:function(e){e=e.replace(/<span(.*?)>/,"<inline$1>");return e.replace(/<\/span>/,"</inline>");},setNonEditable:function(){this.$editor.find(".noneditable").attr("contenteditable",false);},sync:function(){var e="";this.cleanUnverified();if(this.opts.fullpage){e=this.getCodeIframe();}else{e=this.$editor.html();}e=this.syncClean(e);e=this.cleanRemoveEmptyTags(e);e=e.replace(/<\/li><(ul|ol)>([\w\W]*?)<\/(ul|ol)>/gi,"<$1>$2</$1></li>");if(c.trim(e)==="<br>"){e="";}if(this.opts.xhtml){var f=["br","hr","img","link","input","meta"];c.each(f,function(g,h){e=e.replace(new RegExp("<"+h+"(.*?[^/$]?)>","gi"),"<"+h+"$1 />");});}e=this.callback("syncBefore",false,e);this.$source.val(e);this.callback("syncAfter",false,e);if(this.start===false){this.callback("change",false,e);}},syncClean:function(e){if(!this.opts.fullpage){e=this.cleanStripTags(e);}e=c.trim(e);e=this.placeholderRemoveFromCode(e);e=e.replace(/&#x200b;/gi,"");e=e.replace(/&#8203;/gi,"");e=e.replace(/&nbsp;/gi," ");if(this.opts.linkNofollow){e=e.replace(/<a(.*?)rel="nofollow"(.*?)>/gi,"<a$1$2>");e=e.replace(/<a(.*?)>/gi,'<a$1 rel="nofollow">');}e=e.replace("<!--?php","<?php");e=e.replace("?-->","?>");e=e.replace(/<(.*?)class="noeditable"(.*?) contenteditable="false"(.*?)>/gi,'<$1class="noeditable"$2$3>');e=e.replace(/ data-tagblock=""/gi,"");e=e.replace(/<br\s?\/?>\n?<\/(P|H[1-6]|LI|ADDRESS|SECTION|HEADER|FOOTER|ASIDE|ARTICLE)>/gi,"</$1>");e=e.replace(/<span(.*?)id="redactor-image-box"(.*?)>([\w\W]*?)<img(.*?)><\/span>/i,"$3<img$4>");e=e.replace(/<span(.*?)id="redactor-image-resizer"(.*?)>(.*?)<\/span>/i,"");e=e.replace(/<span(.*?)id="redactor-image-editter"(.*?)>(.*?)<\/span>/i,"");e=e.replace(/<span(.*?)>([\w\W]*?)<\/span>/gi,"$2");e=e.replace(/<inline(.*?)>([\w\W]*?)<\/inline>/gi,"<span$1>$2</span>");e=e.replace(/&amp;/gi,"&");e=this.cleanReConvertProtected(e);return e;},buildStart:function(){this.content="";this.$box=c('<div class="redactor_box" />');if(this.$source[0].tagName==="TEXTAREA"){this.opts.textareamode=true;}if(this.opts.mobile===false&&this.isMobile()){this.buildMobile();}else{this.buildContent();if(this.opts.iframe){this.opts.autoresize=false;this.iframeStart();}else{if(this.opts.textareamode){this.buildFromTextarea();}else{this.buildFromElement();}}if(!this.opts.iframe){this.buildOptions();this.buildAfter();}}},buildMobile:function(){if(!this.opts.textareamode){this.$editor=this.$source;this.$editor.hide();this.$source=this.buildCodearea(this.$editor);this.$source.val(this.content);}this.$box.insertAfter(this.$source).append(this.$source);},buildContent:function(){if(this.opts.textareamode){this.content=c.trim(this.$source.val());}else{this.content=c.trim(this.$source.html());}},buildFromTextarea:function(){this.$editor=c("<div />");this.$box.insertAfter(this.$source).append(this.$editor).append(this.$source);this.buildAddClasses(this.$editor);this.buildEnable();},buildFromElement:function(){this.$editor=this.$source;this.$source=this.buildCodearea(this.$editor);this.$box.insertAfter(this.$editor).append(this.$editor).append(this.$source);this.buildEnable();},buildCodearea:function(e){return c("<textarea />").attr("name",e.attr("id")).css("height",this.sourceHeight);},buildAddClasses:function(e){c.each(this.$source.get(0).className.split(/\s+/),function(f,g){e.addClass("redactor_"+g);});},buildEnable:function(){this.$editor.addClass("redactor_editor").attr({contenteditable:true,dir:this.opts.direction});this.$source.attr("dir",this.opts.direction).hide();this.set(this.content,true,false);},buildOptions:function(){var e=this.$editor;if(this.opts.iframe){e=this.$frame;}if(this.opts.tabindex){e.attr("tabindex",this.opts.tabindex);}if(this.opts.minHeight){e.css("min-height",this.opts.minHeight+"px");}if(this.opts.wym){this.$editor.addClass("redactor_editor_wym");}if(!this.opts.autoresize){e.css("height",this.sourceHeight);}},buildAfter:function(){this.start=false;if(this.opts.toolbar){this.opts.toolbar=this.toolbarInit(this.opts.curLang);this.toolbarBuild();}this.modalTemplatesInit();this.buildPlugins();this.buildBindKeyboard();if(this.opts.autosave){this.autosave();}setTimeout(c.proxy(this.observeStart,this),4);if(this.browser("mozilla")){try{this.document.execCommand("enableObjectResizing",false,false);this.document.execCommand("enableInlineTableEditing",false,false);}catch(f){}}if(this.opts.focus){setTimeout(c.proxy(this.focus,this),100);}if(!this.opts.visual){setTimeout(c.proxy(function(){this.opts.visual=true;this.toggle(false);},this),200);}this.callback("init");},buildBindKeyboard:function(){if(this.opts.dragUpload){this.$editor.on("drop.redactor",c.proxy(this.buildEventDrop,this));}this.$editor.on("paste.redactor",c.proxy(this.buildEventPaste,this));this.$editor.on("keydown.redactor",c.proxy(this.buildEventKeydown,this));this.$editor.on("keyup.redactor",c.proxy(this.buildEventKeyup,this));if(c.isFunction(this.opts.textareaKeydownCallback)){this.$source.on("keydown.redactor-textarea",c.proxy(this.opts.textareaKeydownCallback,this));}if(c.isFunction(this.opts.focusCallback)){this.$editor.on("focus.redactor",c.proxy(this.opts.focusCallback,this));}var e;c(document).mousedown(function(f){e=c(f.target);});this.$editor.on("blur.redactor",c.proxy(function(f){if(!c(e).hasClass("redactor_toolbar")&&c(e).parents(".redactor_toolbar").size()==0){this.selectall=false;if(c.isFunction(this.opts.blurCallback)){this.callback("blur",f);}}},this));},buildEventDrop:function(i){i=i.originalEvent||i;if(window.FormData===undefined||!i.dataTransfer){return true;}var h=i.dataTransfer.files.length;if(h==0){return true;}i.preventDefault();var g=i.dataTransfer.files[0];if(this.opts.dnbImageTypes!==false&&this.opts.dnbImageTypes.indexOf(g.type)==-1){return true;}this.bufferSet();var f=c('<div id="redactor-progress-drag" class="redactor-progress redactor-progress-striped"><div id="redactor-progress-bar" class="redactor-progress-bar" style="width: 100%;"></div></div>');c(document.body).append(f);this.dragUploadAjax(this.opts.imageUpload,g,true,f,i,this.opts.imageUploadParam);},buildEventPaste:function(g){var h=false;if(this.browser("webkit")&&navigator.userAgent.indexOf("Chrome")===-1){var f=this.browser("version").split(".");if(f[0]<536){h=true;}}if(h){return true;}if(this.browser("opera")){return true;}if(this.opts.clipboardUpload&&this.buildEventClipboardUpload(g)){return true;}if(this.opts.cleanup){this.rtePaste=true;this.selectionSave();if(!this.selectall){if(this.opts.autoresize===true){this.$editor.height(this.$editor.height());this.saveScroll=this.document.body.scrollTop;}else{this.saveScroll=this.$editor.scrollTop();}}var i=this.extractContent();setTimeout(c.proxy(function(){var e=this.extractContent();this.$editor.append(i);this.selectionRestore();var j=this.getFragmentHtml(e);this.pasteClean(j);if(this.opts.autoresize===true){this.$editor.css("height","auto");}},this),1);}},buildEventClipboardUpload:function(i){var h=i.originalEvent||i;this.clipboardFilePaste=false;if(typeof(h.clipboardData)==="undefined"){return false;}if(h.clipboardData.items){var g=h.clipboardData.items[0].getAsFile();if(g!==null){this.bufferSet();this.clipboardFilePaste=true;var f=new FileReader();f.onload=c.proxy(this.pasteClipboardUpload,this);f.readAsDataURL(g);return true;}}return false;},buildEventKeydown:function(m){if(this.rtePaste){return false;}var f=m.which;var i=m.ctrlKey||m.metaKey;var g=this.getParent();var l=this.getCurrent();var n=this.getBlock();var j=false;this.callback("keydown",m);this.imageResizeHide(false);if((g&&c(g).get(0).tagName==="PRE")||(l&&c(l).get(0).tagName==="PRE")){j=true;if(f===this.keyCode.DOWN){this.insertAfterLastElement(n);}}if(f===this.keyCode.DOWN){if(g&&c(g).get(0).tagName==="BLOCKQUOTE"){this.insertAfterLastElement(g);}if(l&&c(l).get(0).tagName==="BLOCKQUOTE"){this.insertAfterLastElement(l);}}if(i&&!m.shiftKey){this.shortcuts(m,f);}if(i&&f===90&&!m.shiftKey&&!m.altKey){m.preventDefault();if(this.opts.buffer.length){this.bufferUndo();}else{this.document.execCommand("undo",false,false);}return;}else{if(i&&f===90&&m.shiftKey&&!m.altKey){m.preventDefault();if(this.opts.rebuffer.length!=0){this.bufferRedo();}else{this.document.execCommand("redo",false,false);}return;}}if(i&&f===65){this.selectall=true;}else{if(f!=this.keyCode.LEFT_WIN&&!i){this.selectall=false;}}if(f==this.keyCode.ENTER&&!m.shiftKey&&!m.ctrlKey&&!m.metaKey){if(g.nodeType==1&&(g.tagName=="TD"||g.tagName=="TH")){m.preventDefault();this.bufferSet();this.insertNode(document.createElement("br"));this.callback("enter",m);return false;}if(j===true){return this.buildEventKeydownPre(m,l);}else{if(!this.opts.linebreaks){if(n&&this.opts.rBlockTest.test(n.tagName)){this.bufferSet();setTimeout(c.proxy(function(){var o=this.getBlock();if(o.tagName==="DIV"&&!c(o).hasClass("redactor_editor")){var e=c("<p>"+this.opts.invisibleSpace+"</p>");c(o).replaceWith(e);this.selectionStart(e);}},this),1);}else{if(n===false){this.bufferSet();var h=c("<p>"+this.opts.invisibleSpace+"</p>");this.insertNode(h[0]);this.selectionStart(h);this.callback("enter",m);return false;}}}if(this.opts.linebreaks){if(n&&this.opts.rBlockTest.test(n.tagName)){this.bufferSet();setTimeout(c.proxy(function(){var e=this.getBlock();if((e.tagName==="DIV"||e.tagName==="P")&&!c(e).hasClass("redactor_editor")){this.replaceLineBreak(e);}},this),1);}else{return this.buildEventKeydownInsertLineBreak(m);}}if(n.tagName=="BLOCKQUOTE"||n.tagName=="FIGCAPTION"){return this.buildEventKeydownInsertLineBreak(m);}}this.callback("enter",m);}else{if(f===this.keyCode.ENTER&&(m.ctrlKey||m.shiftKey)){this.bufferSet();m.preventDefault();this.insertLineBreak();}}if(f===this.keyCode.TAB&&this.opts.shortcuts){return this.buildEventKeydownTab(m,j);}if(f===this.keyCode.BACKSPACE){this.buildEventKeydownBackspace(l);}},buildEventKeydownPre:function(h,g){h.preventDefault();this.bufferSet();var f=c(g).parent().text();this.insertNode(document.createTextNode("\n"));if(f.search(/\s$/)==-1){this.insertNode(document.createTextNode("\n"));}this.sync();this.callback("enter",h);return false;},buildEventKeydownTab:function(g,f){if(!this.opts.tabFocus){return true;}if(this.isEmpty(this.get())){return true;}g.preventDefault();if(f===true&&!g.shiftKey){this.bufferSet();this.insertNode(document.createTextNode("\t"));this.sync();return false;}else{if(this.opts.tabSpaces!==false){this.bufferSet();this.insertNode(document.createTextNode(Array(this.opts.tabSpaces+1).join("\u00a0")));this.sync();return false;}else{if(!g.shiftKey){this.indentingIndent();}else{this.indentingOutdent();}}}return false;},buildEventKeydownBackspace:function(f){if(typeof f.tagName!=="undefined"&&/^(H[1-6])$/i.test(f.tagName)){var e;if(this.opts.linebreaks===false){e=c("<p>"+this.opts.invisibleSpace+"</p>");}else{e=c("<br>"+this.opts.invisibleSpace);}c(f).replaceWith(e);this.selectionStart(e);}if(typeof f.nodeValue!=="undefined"&&f.nodeValue!==null){if(f.remove&&f.nodeType===3&&f.nodeValue.match(/[^/\u200B]/g)==null){f.remove();}}},buildEventKeydownInsertLineBreak:function(f){this.bufferSet();f.preventDefault();this.insertLineBreak();this.callback("enter",f);return;},buildEventKeyup:function(l){if(this.rtePaste){return false;}var f=l.which;var h=this.getParent();var j=this.getCurrent();if(!this.opts.linebreaks&&j.nodeType==3&&(h==false||h.tagName=="BODY")){var i=c("<p>").append(c(j).clone());c(j).replaceWith(i);var g=c(i).next();if(typeof(g[0])!=="undefined"&&g[0].tagName=="BR"){g.remove();}this.selectionEnd(i);}if((this.opts.convertLinks||this.opts.convertImageLinks||this.opts.convertVideoLinks)&&f===this.keyCode.ENTER){this.buildEventKeyupConverters();}if(this.opts.linebreaks===false&&(f===this.keyCode.DELETE||f===this.keyCode.BACKSPACE)){return this.formatEmpty(l);}this.callback("keyup",l);this.sync();},buildEventKeyupConverters:function(){this.formatLinkify(this.opts.linkProtocol,this.opts.convertLinks,this.opts.convertImageLinks,this.opts.convertVideoLinks,this.opts.linkSize);setTimeout(c.proxy(function(){if(this.opts.convertImageLinks){this.observeImages();}if(this.opts.observeLinks){this.observeLinks();}},this),5);},buildPlugins:function(){if(!this.opts.plugins){return;}c.each(this.opts.plugins,c.proxy(function(e,f){if(RedactorPlugins[f]){c.extend(this,RedactorPlugins[f]);if(c.isFunction(RedactorPlugins[f].init)){this.init();}}},this));},iframeStart:function(){this.iframeCreate();if(this.opts.textareamode){this.iframeAppend(this.$source);}else{this.$sourceOld=this.$source.hide();this.$source=this.buildCodearea(this.$sourceOld);this.iframeAppend(this.$sourceOld);}},iframeAppend:function(e){this.$source.attr("dir",this.opts.direction).hide();this.$box.insertAfter(e).append(this.$frame).append(this.$source);},iframeCreate:function(){this.$frame=c('<iframe style="width: 100%;" frameborder="0" />').one("load",c.proxy(function(){if(this.opts.fullpage){this.iframePage();if(this.content===""){this.content=this.opts.invisibleSpace;}this.$frame.contents()[0].write(this.content);this.$frame.contents()[0].close();var e=setInterval(c.proxy(function(){if(this.$frame.contents().find("body").html()){clearInterval(e);this.iframeLoad();}},this),0);}else{this.iframeLoad();}},this));},iframeDoc:function(){return this.$frame[0].contentWindow.document;},iframePage:function(){var e=this.iframeDoc();if(e.documentElement){e.removeChild(e.documentElement);}return e;},iframeAddCss:function(e){e=e||this.opts.css;if(this.isString(e)){this.$frame.contents().find("head").append('<link rel="stylesheet" href="'+e+'" />');}if(c.isArray(e)){c.each(e,c.proxy(function(g,f){this.iframeAddCss(f);},this));}},iframeLoad:function(){this.$editor=this.$frame.contents().find("body").attr({contenteditable:true,dir:this.opts.direction});if(this.$editor[0]){this.document=this.$editor[0].ownerDocument;this.window=this.document.defaultView||window;}this.iframeAddCss();if(this.opts.fullpage){this.setFullpageOnInit(this.$editor.html());}else{this.set(this.content,true,false);}this.buildOptions();this.buildAfter();},placeholderStart:function(e){if(this.isEmpty(e)){if(this.$element.attr("placeholder")){this.opts.placeholder=this.$element.attr("placeholder");}if(this.opts.placeholder===""){this.opts.placeholder=false;}if(this.opts.placeholder!==false){this.opts.focus=false;this.$editor.one("focus.redactor_placeholder",c.proxy(this.placeholderFocus,this));return c('<span class="redactor_placeholder" data-redactor="verified">').attr("contenteditable",false).text(this.opts.placeholder);}}return false;},placeholderFocus:function(){this.$editor.find("span.redactor_placeholder").remove();var e="";if(this.opts.linebreaks===false){e=this.opts.emptyHtml;}this.$editor.off("focus.redactor_placeholder");this.$editor.html(e);if(this.opts.linebreaks===false){this.selectionStart(this.$editor.children()[0]);}else{this.focus();}this.sync();},placeholderRemove:function(){this.opts.placeholder=false;this.$editor.find("span.redactor_placeholder").remove();this.$editor.off("focus.redactor_placeholder");},placeholderRemoveFromCode:function(e){return e.replace(/<span class="redactor_placeholder"(.*?)>(.*?)<\/span>/i,"");},shortcuts:function(g,f){if(!this.opts.shortcuts){return;}if(!g.altKey){if(f===77){this.shortcutsLoad(g,"removeFormat");}else{if(f===66){this.shortcutsLoad(g,"bold");}else{if(f===73){this.shortcutsLoad(g,"italic");}else{if(f===74){this.shortcutsLoad(g,"insertunorderedlist");}else{if(f===75){this.shortcutsLoad(g,"insertorderedlist");}else{if(f===72){this.shortcutsLoad(g,"superscript");}else{if(f===76){this.shortcutsLoad(g,"subscript");}}}}}}}}else{if(f===48){this.shortcutsLoadFormat(g,"p");}else{if(f===49){this.shortcutsLoadFormat(g,"h1");}else{if(f===50){this.shortcutsLoadFormat(g,"h2");}else{if(f===51){this.shortcutsLoadFormat(g,"h3");}else{if(f===52){this.shortcutsLoadFormat(g,"h4");}else{if(f===53){this.shortcutsLoadFormat(g,"h5");}else{if(f===54){this.shortcutsLoadFormat(g,"h6");}}}}}}}}},shortcutsLoad:function(g,f){g.preventDefault();this.execCommand(f,false);},shortcutsLoadFormat:function(g,f){g.preventDefault();this.formatBlocks(f);},focus:function(){if(!this.browser("opera")){this.window.setTimeout(c.proxy(this.focusSet,this,true),1);}else{this.$editor.focus();}},focusEnd:function(){this.focusSet();},focusSet:function(g){this.$editor.focus();var e=this.getRange();e.selectNodeContents(this.$editor[0]);e.collapse(g||false);var f=this.getSelection();f.removeAllRanges();f.addRange(e);},toggle:function(e){if(this.opts.visual){this.toggleCode(e);}else{this.toggleVisual();}},toggleVisual:function(){var e=this.$source.hide().val();if(typeof this.modified!=="undefined"){this.modified=this.cleanRemoveSpaces(this.modified,false)!==this.cleanRemoveSpaces(e,false);}if(this.modified){if(this.opts.fullpage&&e===""){this.setFullpageOnInit(e);}else{this.set(e);if(this.opts.fullpage){this.buildBindKeyboard();}}}if(this.opts.iframe){this.$frame.show();}else{this.$editor.show();}if(this.opts.fullpage){this.$editor.attr("contenteditable",true);}this.$source.off("keydown.redactor-textarea-indenting");this.$editor.focus();this.selectionRestore();this.observeStart();this.buttonActiveVisual();this.buttonInactive("html");this.opts.visual=true;},toggleCode:function(g){if(g!==false){this.selectionSave();}var e=null;if(this.opts.iframe){e=this.$frame.height();if(this.opts.fullpage){this.$editor.removeAttr("contenteditable");}this.$frame.hide();}else{e=this.$editor.innerHeight();this.$editor.hide();}var f=this.$source.val();if(f!==""&&this.opts.tidyHtml){this.$source.val(this.cleanHtml(f));}this.modified=f;this.$source.height(e).show().focus();this.$source.on("keydown.redactor-textarea-indenting",this.textareaIndenting);this.buttonInactiveVisual();this.buttonActive("html");this.opts.visual=false;},textareaIndenting:function(g){if(g.keyCode===9){var f=c(this);var h=f.get(0).selectionStart;f.val(f.val().substring(0,h)+"\t"+f.val().substring(f.get(0).selectionEnd));f.get(0).selectionStart=f.get(0).selectionEnd=h+1;return false;}},autosave:function(){var e=false;this.autosaveInterval=setInterval(c.proxy(function(){var f=this.get();if(e!==f){c.ajax({url:this.opts.autosave,type:"post",data:this.$source.attr("name")+"="+escape(encodeURIComponent(f)),success:c.proxy(function(g){this.callback("autosave",false,g);e=f;},this)});}},this),this.opts.autosaveInterval*1000);},toolbarBuild:function(){if(this.opts.air){this.opts.buttons=this.opts.airButtons;}else{if(!this.opts.buttonSource){var f=this.opts.buttons.indexOf("html"),g=this.opts.buttons[f+1];this.opts.buttons.splice(f,1);if(g==="|"){this.opts.buttons.splice(f,1);}}}c.extend(this.opts.toolbar,this.opts.buttonsCustom);c.each(this.opts.buttonsAdd,c.proxy(function(h,j){this.opts.buttons.push(j);},this));if(this.opts.toolbar){c.each(this.opts.toolbar.formatting.dropdown,c.proxy(function(h,j){if(c.inArray(h,this.opts.formattingTags)=="-1"){delete this.opts.toolbar.formatting.dropdown[h];}},this));}if(this.opts.buttons.length===0){return false;}this.airEnable();this.$toolbar=c("<ul>").addClass("redactor_toolbar").attr("id","redactor_toolbar_"+this.uuid);if(this.opts.air){this.$air=c('<div class="redactor_air">').attr("id","redactor_air_"+this.uuid).hide();this.$air.append(this.$toolbar);c("body").append(this.$air);}else{if(this.opts.toolbarExternal){c(this.opts.toolbarExternal).html(this.$toolbar);}else{this.$box.prepend(this.$toolbar);}}c.each(this.opts.buttons,c.proxy(function(j,l){if(l==="|"){this.$toolbar.append(c(this.opts.buttonSeparator));}else{if(this.opts.toolbar[l]){var h=this.opts.toolbar[l];if(this.opts.fileUpload===false&&l==="file"){return true;}this.$toolbar.append(c("<li>").append(this.buttonBuild(l,h)));}}},this));this.$toolbar.find("a").attr("tabindex","-1");if(this.opts.toolbarFixed){this.toolbarObserveScroll();c(this.opts.toolbarFixedTarget).on("scroll.redactor",c.proxy(this.toolbarObserveScroll,this));}if(this.opts.activeButtons){var e=c.proxy(this.buttonActiveObserver,this);this.$editor.on("mouseup.redactor keyup.redactor",e);}},toolbarObserveScroll:function(){var i=c(this.opts.toolbarFixedTarget).scrollTop();var g=this.$box.offset().top;var h=0;var e=g+this.$box.height()+40;if(i>g){var f="100%";if(this.opts.toolbarFixedBox){h=this.$box.offset().left;f=this.$box.innerWidth();this.$toolbar.addClass("toolbar_fixed_box");}this.toolbarFixed=true;this.$toolbar.css({position:"fixed",width:f,zIndex:1005,top:this.opts.toolbarFixedTopOffset+"px",left:h});if(i<e){this.$toolbar.css("visibility","visible");}else{this.$toolbar.css("visibility","hidden");}}else{this.toolbarFixed=false;this.$toolbar.css({position:"relative",width:"auto",top:0,left:h});if(this.opts.toolbarFixedBox){this.$toolbar.removeClass("toolbar_fixed_box");}}},airEnable:function(){if(!this.opts.air){return;}this.$editor.on("mouseup.redactor keyup.redactor",this,c.proxy(function(g){var i=this.getSelectionText();if(g.type==="mouseup"&&i!=""){this.airShow(g);}if(g.type==="keyup"&&g.shiftKey&&i!=""){var f=c(this.getElement(this.getSelection().focusNode)),h=f.offset();h.height=f.height();this.airShow(h,true);}},this));},airShow:function(j,f){if(!this.opts.air){return;}var i,h;c(".redactor_air").hide();if(f){i=j.left;h=j.top+j.height+14;if(this.opts.iframe){h+=this.$box.position().top-c(this.document).scrollTop();i+=this.$box.position().left;}}else{var g=this.$air.innerWidth();i=j.clientX;if(c(this.document).width()<(i+g)){i-=g;}h=j.clientY+14;if(this.opts.iframe){h+=this.$box.position().top;i+=this.$box.position().left;}else{h+=c(this.document).scrollTop();}}this.$air.css({left:i+"px",top:h+"px"}).show();this.airBindHide();},airBindHide:function(){if(!this.opts.air){return;}var e=c.proxy(function(f){c(f).on("mousedown.redactor",c.proxy(function(g){if(c(g.target).closest(this.$toolbar).length===0){this.$air.fadeOut(100);this.selectionRemove();c(f).off(g);}},this)).on("keydown.redactor",c.proxy(function(g){if(g.which===this.keyCode.ESC){this.getSelection().collapseToStart();}this.$air.fadeOut(100);c(f).off(g);},this));},this);e(document);if(this.opts.iframe){e(this.document);}},airBindMousemoveHide:function(){if(!this.opts.air){return;}var e=c.proxy(function(f){c(f).on("mousemove.redactor",c.proxy(function(g){if(c(g.target).closest(this.$toolbar).length===0){this.$air.fadeOut(100);c(f).off(g);}},this));},this);e(document);if(this.opts.iframe){e(this.document);}},dropdownBuild:function(f,e){c.each(e,c.proxy(function(i,h){if(!h.className){h.className="";}var g;if(h.name==="separator"){g=c('<a class="redactor_separator_drop">');}else{g=c('<a href="#" class="'+h.className+" redactor_dropdown_"+i+'">'+h.title+"</a>");g.on("click",c.proxy(function(j){if(j.preventDefault){j.preventDefault();}if(this.browser("msie")){j.returnValue=false;}if(h.callback){h.callback.call(this,i,g,h,j);}if(h.exec){this.execCommand(h.exec,i);}if(h.func){this[h.func](i);}this.buttonActiveObserver();if(this.opts.air){this.$air.fadeOut(100);}},this));}f.append(g);},this));},dropdownShow:function(l,p){if(!this.opts.visual){l.preventDefault();return false;}var m=this.$toolbar.find(".redactor_dropdown_box_"+p);var f=this.buttonGet(p);if(f.hasClass("dropact")){this.dropdownHideAll();}else{this.dropdownHideAll();this.buttonActive(p);f.addClass("dropact");var q=f.position();if(this.toolbarFixed){q=f.offset();}var n=m.width();if((q.left+n)>c(document).width()){q.left-=n;}var h=q.left+"px";var i=29;var j="absolute";var o=i+"px";if(this.opts.toolbarFixed&&this.toolbarFixed){j="fixed";}else{if(!this.opts.air){o=q.top+i+"px";}}m.css({position:j,left:h,top:o}).show();}var g=c.proxy(function(r){this.dropdownHide(r,m);},this);c(document).one("click",g);this.$editor.one("click",g);l.stopPropagation();},dropdownHideAll:function(){this.$toolbar.find("a.dropact").removeClass("redactor_act").removeClass("dropact");c(".redactor_dropdown").hide();},dropdownHide:function(g,f){if(!c(g.target).hasClass("dropact")){f.removeClass("dropact");this.dropdownHideAll();}},buttonBuild:function(h,e){var f=c('<a href="javascript:;" title="'+e.title+'" tabindex="-1" class="redactor_btn redactor_btn_'+h+'"></a>');f.on("click",c.proxy(function(i){if(i.preventDefault){i.preventDefault();}if(this.browser("msie")){i.returnValue=false;}if(f.hasClass("redactor_button_disabled")){return false;}if(this.isFocused()===false&&!e.exec){this.$editor.focus();}if(e.exec){this.$editor.focus();this.execCommand(e.exec,h);this.airBindMousemoveHide();}else{if(e.func&&e.func!=="show"){this[e.func](h);this.airBindMousemoveHide();}else{if(e.callback){e.callback.call(this,h,f,e,i);this.airBindMousemoveHide();}else{if(e.dropdown){this.dropdownShow(i,h);}}}}this.buttonActiveObserver(false,h);},this));if(e.dropdown){var g=c('<div class="redactor_dropdown redactor_dropdown_box_'+h+'" style="display: none;">');g.appendTo(this.$toolbar);this.dropdownBuild(g,e.dropdown);}return f;},buttonGet:function(e){if(!this.opts.toolbar){return false;}return c(this.$toolbar.find("a.redactor_btn_"+e));},buttonActiveToggle:function(f){var e=this.buttonGet(f);if(e.hasClass("redactor_act")){e.removeClass("redactor_act");}else{e.addClass("redactor_act");}},buttonActive:function(e){this.buttonGet(e).addClass("redactor_act");},buttonInactive:function(e){this.buttonGet(e).removeClass("redactor_act");},buttonInactiveAll:function(e){c.each(this.opts.toolbar,c.proxy(function(f){if(f!=e){this.buttonInactive(f);}},this));},buttonActiveVisual:function(){this.$toolbar.find("a.redactor_btn").not("a.redactor_btn_html").removeClass("redactor_button_disabled");},buttonInactiveVisual:function(){this.$toolbar.find("a.redactor_btn").not("a.redactor_btn_html").addClass("redactor_button_disabled");},buttonChangeIcon:function(e,f){this.buttonGet(e).addClass("redactor_btn_"+f);},buttonRemoveIcon:function(e,f){this.buttonGet(e).removeClass("redactor_btn_"+f);},buttonAddSeparator:function(){this.$toolbar.append(c(this.opts.buttonSeparator));},buttonAddSeparatorAfter:function(e){this.buttonGet(e).parent().after(c(this.opts.buttonSeparator));},buttonAddSeparatorBefore:function(e){this.buttonGet(e).parent().before(c(this.opts.buttonSeparator));},buttonRemoveSeparatorAfter:function(e){this.buttonGet(e).parent().next().remove();},buttonRemoveSeparatorBefore:function(e){this.buttonGet(e).parent().prev().remove();},buttonSetRight:function(e){if(!this.opts.toolbar){return;}this.buttonGet(e).parent().addClass("redactor_btn_right");},buttonSetLeft:function(e){if(!this.opts.toolbar){return;}this.buttonGet(e).parent().removeClass("redactor_btn_right");},buttonAdd:function(f,g,i,h){if(!this.opts.toolbar){return;}var e=this.buttonBuild(f,{title:g,callback:i,dropdown:h});this.$toolbar.append(c("<li>").append(e));},buttonAddFirst:function(f,g,i,h){if(!this.opts.toolbar){return;}var e=this.buttonBuild(f,{title:g,callback:i,dropdown:h});this.$toolbar.prepend(c("<li>").append(e));},buttonAddAfter:function(l,f,h,j,i){if(!this.opts.toolbar){return;}var e=this.buttonBuild(f,{title:h,callback:j,dropdown:i});var g=this.buttonGet(l);if(g.size()!==0){g.parent().after(c("<li>").append(e));}else{this.$toolbar.append(c("<li>").append(e));}},buttonAddBefore:function(i,f,h,l,j){if(!this.opts.toolbar){return;}var e=this.buttonBuild(f,{title:h,callback:l,dropdown:j});var g=this.buttonGet(i);if(g.size()!==0){g.parent().before(c("<li>").append(e));}else{this.$toolbar.append(c("<li>").append(e));}},buttonRemove:function(e,g){var f=this.buttonGet(e);if(g){f.parent().next().remove();}f.parent().removeClass("redactor_btn_right");f.remove();},buttonActiveObserver:function(h,j){var f=this.getParent();this.buttonInactiveAll(j);if(h===false&&j!=="html"){if(c.inArray(j,this.opts.activeButtons)!=-1){this.buttonActiveToggle(j);}return;}if(f&&f.tagName==="A"){this.$toolbar.find("a.redactor_dropdown_link").text(this.opts.curLang.link_edit);}else{this.$toolbar.find("a.redactor_dropdown_link").text(this.opts.curLang.link_insert);}if(this.opts.activeButtonsAdd){c.each(this.opts.activeButtonsAdd,c.proxy(function(e,l){this.opts.activeButtons.push(l);},this));c.extend(this.opts.activeButtonsStates,this.opts.activeButtonsAdd);}c.each(this.opts.activeButtonsStates,c.proxy(function(e,l){if(c(f).closest(e,this.$editor.get()[0]).length!=0){this.buttonActive(l);}},this));var g=c(f).closest(this.opts.alignmentTags.toString().toLowerCase(),this.$editor[0]);if(g.length){var i=g.css("text-align");switch(i){case"right":this.buttonActive("alignright");break;case"center":this.buttonActive("aligncenter");break;case"justify":this.buttonActive("justify");break;default:this.buttonActive("alignleft");break;}}},exec:function(f,g,e){if(f==="formatblock"&&this.browser("msie")){g="<"+g+">";}if(f==="inserthtml"&&this.browser("msie")){this.$editor.focus();this.document.selection.createRange().pasteHTML(g);}else{this.document.execCommand(f,false,g);}if(e!==false){this.sync();}this.callback("execCommand",f,g);},execCommand:function(h,g,p){if(!this.opts.visual){this.$source.focus();return false;}if(h==="inserthtml"){this.insertHtml(g,p);this.callback("execCommand",h,g);return;}if(this.currentOrParentIs("PRE")&&!this.opts.formattingPre){return false;}if(h==="insertunorderedlist"||h==="insertorderedlist"){this.bufferSet();var q=this.getParent();var l=c(q).closest("ol, ul");var j=false;if(l.length){j=true;var n=l[0].tagName;if((h==="insertunorderedlist"&&n==="OL")||(h==="insertorderedlist"&&n==="UL")){j=false;}}this.selectionSave();if(j){var f=this.getNodes();var e=this.getBlocks(f);if(typeof f[0]!="undefined"&&f.length>1&&f[0].nodeType==3){e.unshift(this.getBlock());}var i="",r="";c.each(e,c.proxy(function(v,w){if(w.tagName=="LI"){var u=c(w);var t=u.clone();t.find("ul","ol").remove();if(this.opts.linebreaks===false){i+=this.outerHtml(c("<p>").append(t.contents()));}else{i+=t.html()+"<br>";}if(v==0){u.addClass("redactor-replaced").empty();r=this.outerHtml(u);}else{u.remove();}}},this));html=this.$editor.html().replace(r,"</"+n+">"+i+"<"+n+">");this.$editor.html(html);this.$editor.find(n+":empty").remove();}else{this.document.execCommand(h);var q=this.getParent();var l=c(q).closest("ol, ul");if(l.length){if((this.browser("msie")||this.browser("mozilla"))&&q.tagName!=="LI"){c(q).replaceWith(c(q).html());}var m=l.parent();if(this.isParentRedactor(m)&&this.nodeTestBlocks(m[0])){m.replaceWith(m.contents());}}if(this.browser("mozilla")){this.$editor.focus();}}this.selectionRestore();this.sync();this.callback("execCommand",h,g);return;}if(h==="unlink"){this.bufferSet();var o=this.currentOrParentIs("A");if(o){c(o).replaceWith(c(o).text());this.sync();this.callback("execCommand",h,g);return;}}this.exec(h,g,p);if(h==="inserthorizontalrule"){this.$editor.find("hr").removeAttr("id");}},indentingIndent:function(){this.indentingStart("indent");},indentingOutdent:function(){this.indentingStart("outdent");},indentingStart:function(h){this.bufferSet();if(h==="indent"){var i=this.getBlock();this.selectionSave();if(i&&i.tagName=="LI"){var n=this.getParent();var j=c(n).closest("ol, ul");var m=j[0].tagName;var f=this.getBlocks();c.each(f,function(r,t){if(t.tagName=="LI"){var q=c(t).prev();if(q.size()!=0&&q[0].tagName=="LI"){var p=q.children("ul, ol");if(p.size()==0){q.append(c("<"+m+">").append(t));}else{p.append(t);}}}});}else{if(i===false&&this.opts.linebreaks===true){this.exec("formatBlock","blockquote");var o=this.getBlock();var i=c('<div data-tagblock="">').html(c(o).html());c(o).replaceWith(i);var g=this.normalize(c(i).css("margin-left"))+this.opts.indentValue;c(i).css("margin-left",g+"px");}else{var e=this.getBlocks();c.each(e,c.proxy(function(q,r){var p=false;if(r.tagName==="TD"){return;}if(c.inArray(r.tagName,this.opts.alignmentTags)!==-1){p=c(r);}else{p=c(r).closest(this.opts.alignmentTags.toString().toLowerCase(),this.$editor[0]);}var s=this.normalize(p.css("margin-left"))+this.opts.indentValue;p.css("margin-left",s+"px");},this));}}this.selectionRestore();}else{this.selectionSave();var i=this.getBlock();if(i&&i.tagName=="LI"){var f=this.getBlocks();var l=0;this.insideOutdent(i,l,f);}else{var e=this.getBlocks();c.each(e,c.proxy(function(q,r){var p=false;if(c.inArray(r.tagName,this.opts.alignmentTags)!==-1){p=c(r);}else{p=c(r).closest(this.opts.alignmentTags.toString().toLowerCase(),this.$editor[0]);}var s=this.normalize(p.css("margin-left"))-this.opts.indentValue;if(s<=0){if(this.opts.linebreaks===true&&typeof(p.data("tagblock"))!=="undefined"){p.replaceWith(p.html());}else{p.css("margin-left","");this.removeEmptyAttr(p,"style");}}else{p.css("margin-left",s+"px");}},this));}this.selectionRestore();}this.sync();},insideOutdent:function(e,g,f){if(e&&e.tagName=="LI"){var h=c(e).parent().parent();if(h.size()!=0&&h[0].tagName=="LI"){h.after(e);}else{if(typeof f[g]!="undefined"){e=f[g];g++;this.insideOutdent(e,g,f);}else{this.execCommand("insertunorderedlist");}}}},alignmentLeft:function(){this.alignmentSet("","JustifyLeft");},alignmentRight:function(){this.alignmentSet("right","JustifyRight");},alignmentCenter:function(){this.alignmentSet("center","JustifyCenter");},alignmentJustify:function(){this.alignmentSet("justify","JustifyFull");},alignmentSet:function(f,h){this.bufferSet();if(this.oldIE()){this.document.execCommand(h,false,false);return true;}this.selectionSave();var i=this.getBlock();if(!i&&this.opts.linebreaks){this.exec("formatBlock","blockquote");var e=this.getBlock();var i=c('<div data-tagblock="">').html(c(e).html());c(e).replaceWith(i);c(i).css("text-align",f);this.removeEmptyAttr(i,"style");if(f==""&&typeof(c(i).data("tagblock"))!=="undefined"){c(i).replaceWith(c(i).html());}}else{var g=this.getBlocks();c.each(g,c.proxy(function(l,m){var j=false;if(c.inArray(m.tagName,this.opts.alignmentTags)!==-1){j=c(m);}else{j=c(m).closest(this.opts.alignmentTags.toString().toLowerCase(),this.$editor[0]);}if(j){j.css("text-align",f);this.removeEmptyAttr(j,"style");}},this));}this.selectionRestore();this.sync();},cleanEmpty:function(e){var f=this.placeholderStart(e);if(f!==false){return f;}if(this.opts.linebreaks===false){if(e===""){e=this.opts.emptyHtml;}else{if(e.search(/^<hr\s?\/?>$/gi)!==-1){e="<hr>"+this.opts.emptyHtml;}}}return e;},cleanConverters:function(e){if(this.opts.convertDivs){e=e.replace(/<div(.*?)>([\w\W]*?)<\/div>/gi,"<p$1>$2</p>");}if(this.opts.paragraphy){e=this.cleanParagraphy(e);}return e;},cleanConvertProtected:function(e){if(this.opts.templateVars){e=e.replace(/\{\{(.*?)\}\}/gi,"<!-- template double $1 -->");e=e.replace(/\{(.*?)\}/gi,"<!-- template $1 -->");}e=e.replace(/<script(.*?)>([\w\W]*?)<\/script>/gi,'<title type="text/javascript" style="display: none;" class="redactor-script-tag"$1>$2</title>');e=e.replace(/<style(.*?)>([\w\W]*?)<\/style>/gi,'<section$1 style="display: none;" rel="redactor-style-tag">$2</section>');e=e.replace(/<form(.*?)>([\w\W]*?)<\/form>/gi,'<section$1 rel="redactor-form-tag">$2</section>');if(this.opts.phpTags){e=e.replace(/<\?php([\w\W]*?)\?>/gi,'<section style="display: none;" rel="redactor-php-tag">$1</section>');}else{e=e.replace(/<\?php([\w\W]*?)\?>/gi,"");}return e;},cleanReConvertProtected:function(e){if(this.opts.templateVars){e=e.replace(/<!-- template double (.*?) -->/gi,"{{$1}}");e=e.replace(/<!-- template (.*?) -->/gi,"{$1}");}e=e.replace(/<title type="text\/javascript" style="display: none;" class="redactor-script-tag"(.*?)>([\w\W]*?)<\/title>/gi,'<script$1 type="text/javascript">$2<\/script>');e=e.replace(/<section(.*?) style="display: none;" rel="redactor-style-tag">([\w\W]*?)<\/section>/gi,"<style$1>$2</style>");e=e.replace(/<section(.*?)rel="redactor-form-tag"(.*?)>([\w\W]*?)<\/section>/gi,"<form$1$2>$3</form>");if(this.opts.phpTags){e=e.replace(/<section style="display: none;" rel="redactor-php-tag">([\w\W]*?)<\/section>/gi,"<?php\r\n$1\r\n?>");}return e;},cleanRemoveSpaces:function(f,e){if(e!==false){var e=[];var h=f.match(/<(pre|style|script|title)(.*?)>([\w\W]*?)<\/(pre|style|script|title)>/gi);if(h===null){h=[];}if(this.opts.phpTags){var g=f.match(/<\?php([\w\W]*?)\?>/gi);if(g){h=c.merge(h,g);}}if(h){c.each(h,function(j,l){f=f.replace(l,"buffer_"+j);e.push(l);});}}f=f.replace(/\n/g," ");f=f.replace(/[\t]*/g,"");f=f.replace(/\n\s*\n/g,"\n");f=f.replace(/^[\s\n]*/g," ");f=f.replace(/[\s\n]*$/g," ");f=f.replace(/>\s{2,}</g,"> <");f=this.cleanReplacer(f,e);f=f.replace(/\n\n/g,"\n");return f;},cleanReplacer:function(f,e){if(e===false){return f;}c.each(e,function(g,h){f=f.replace("buffer_"+g,h);});return f;},cleanRemoveEmptyTags:function(h){h=h.replace(/<span>([\w\W]*?)<\/span>/gi,"$1");h=h.replace(/[\u200B-\u200D\uFEFF]/g,"");var j=["<b>\\s*</b>","<b>&nbsp;</b>","<em>\\s*</em>"];var g=["<pre></pre>","<blockquote>\\s*</blockquote>","<dd></dd>","<dt></dt>","<ul></ul>","<ol></ol>","<li></li>","<table></table>","<tr></tr>","<span>\\s*<span>","<span>&nbsp;<span>","<p>\\s*</p>","<p></p>","<p>&nbsp;</p>","<p>\\s*<br>\\s*</p>","<div>\\s*</div>","<div>\\s*<br>\\s*</div>"];if(this.opts.removeEmptyTags){g=g.concat(j);}else{g=j;}var e=g.length;for(var f=0;f<e;++f){h=h.replace(new RegExp(g[f],"gi"),"");}return h;},cleanParagraphy:function(l){l=c.trim(l);if(this.opts.linebreaks===true){return l;}if(l===""||l==="<p></p>"){return this.opts.emptyHtml;}l=l+"\n";var n=[];var j=l.match(/<(table|div|pre|object)(.*?)>([\w\W]*?)<\/(table|div|pre|object)>/gi);if(!j){j=[];}var m=l.match(/<!--([\w\W]*?)-->/gi);if(m){j=c.merge(j,m);}if(this.opts.phpTags){var f=l.match(/<section(.*?)rel="redactor-php-tag">([\w\W]*?)<\/section>/gi);if(f){j=c.merge(j,f);}}if(j){c.each(j,function(p,q){n[p]=q;l=l.replace(q,"{replace"+p+"}\n");});}l=l.replace(/<br \/>\s*<br \/>/gi,"\n\n");function h(q,i,p){return l.replace(new RegExp(q,i),p);}var e="(comment|html|body|head|title|meta|style|script|link|iframe|table|thead|tfoot|caption|col|colgroup|tbody|tr|td|th|div|dl|dd|dt|ul|ol|li|pre|select|option|form|map|area|blockquote|address|math|style|p|h[1-6]|hr|fieldset|legend|section|article|aside|hgroup|header|footer|nav|figure|figcaption|details|menu|summary)";l=h("(<"+e+"[^>]*>)","gi","\n$1");l=h("(</"+e+">)","gi","$1\n\n");l=h("\r\n","g","\n");l=h("\r","g","\n");l=h("/\n\n+/","g","\n\n");var o=l.split(new RegExp("\ns*\n","g"),-1);l="";for(var g in o){if(o.hasOwnProperty(g)){if(o[g].search("{replace")==-1){l+="<p>"+o[g].replace(/^\n+|\n+$/g,"")+"</p>";}else{l+=o[g];}}}if(l.search(/<blockquote/gi)!==-1){c.each(l.match(/<blockquote(.*?)>([\w\W]*?)<\/blockquote>/gi),function(p,q){var r="";r=q.replace("<p>","");r=r.replace("</p>","<br>");l=l.replace(q,r);});}l=h("<p>s*</p>","gi","");l=h("<p>([^<]+)</(div|address|form)>","gi","<p>$1</p></$2>");l=h("<p>s*(</?"+e+"[^>]*>)s*</p>","gi","$1");l=h("<p>(<li.+?)</p>","gi","$1");l=h("<p>s*(</?"+e+"[^>]*>)","gi","$1");l=h("(</?"+e+"[^>]*>)s*</p>","gi","$1");l=h("(</?"+e+"[^>]*>)s*<br />","gi","$1");l=h("<br />(s*</?(?:p|li|div|dl|dd|dt|th|pre|td|ul|ol)[^>]*>)","gi","$1");l=h("\n</p>","gi","</p>");l=h("<li><p>","gi","<li>");l=h("</p></li>","gi","</li>");l=h("</li><p>","gi","</li>");l=h("<p>\t?\n?<p>","gi","<p>");l=h("</dt><p>","gi","</dt>");l=h("</dd><p>","gi","</dd>");l=h("<br></p></blockquote>","gi","</blockquote>");l=h("<p>\t*</p>","gi","");c.each(n,function(p,q){l=l.replace("{replace"+p+"}",q);});return c.trim(l);},cleanConvertInlineTags:function(e){var f="strong";if(this.opts.boldTag==="b"){f="b";}var g="em";if(this.opts.italicTag==="i"){g="i";}e=e.replace(/<span style="font-style: italic;">([\w\W]*?)<\/span>/gi,"<"+g+">$1</"+g+">");e=e.replace(/<span style="font-weight: bold;">([\w\W]*?)<\/span>/gi,"<"+f+">$1</"+f+">");if(this.opts.boldTag==="strong"){e=e.replace(/<b>([\w\W]*?)<\/b>/gi,"<strong>$1</strong>");}else{e=e.replace(/<strong>([\w\W]*?)<\/strong>/gi,"<b>$1</b>");}if(this.opts.italicTag==="em"){e=e.replace(/<i>([\w\W]*?)<\/i>/gi,"<em>$1</em>");}else{e=e.replace(/<em>([\w\W]*?)<\/em>/gi,"<i>$1</i>");}e=e.replace(/<strike>([\w\W]*?)<\/strike>/gi,"<del>$1</del>");return e;},cleanStripTags:function(g){if(g==""||typeof g=="undefined"){return g;}var h=false;if(this.opts.allowedTags!==false){h=true;}var e=h===true?this.opts.allowedTags:this.opts.deniedTags;var f=/<\/?([a-z][a-z0-9]*)\b[^>]*>/gi;g=g.replace(f,function(j,i){if(h===true){return c.inArray(i.toLowerCase(),e)>"-1"?j:"";}else{return c.inArray(i.toLowerCase(),e)>"-1"?"":j;}});g=this.cleanConvertInlineTags(g);return g;},cleanSavePreCode:function(e,f){var g=e.match(/<(pre|code)(.*?)>([\w\W]*?)<\/(pre|code)>/gi);if(g!==null){c.each(g,c.proxy(function(j,l){var h=l.match(/<(pre|code)(.*?)>([\w\W]*?)<\/(pre|code)>/i);h[3]=h[3].replace(/&nbsp;/g," ");if(f!==false){h[3]=this.cleanEncodeEntities(h[3]);}e=e.replace(l,"<"+h[1]+h[2]+">"+h[3]+"</"+h[1]+">");},this));}return e;},cleanEncodeEntities:function(e){e=String(e).replace(/&amp;/g,"&").replace(/&lt;/g,"<").replace(/&gt;/g,">").replace(/&quot;/g,'"');return String(e).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;");},cleanUnverified:function(){var e=this.$editor.find("li, img, a, b, strong, sub, sup, i, em, u, small, strike, del, span, cite");e.filter('[style*="background-color: transparent;"][style*="line-height"]').css("background-color","").css("line-height","");e.filter('[style*="background-color: transparent;"]').css("background-color","");e.css("line-height","");c.each(e,c.proxy(function(f,g){this.removeEmptyAttr(g,"style");},this));this.$editor.find('div[style="text-align: -webkit-auto;"]').contents().unwrap();},cleanHtml:function(f){var j=0,m=f.length,l=0,e=null,g=null,p="",h="",o="";this.cleanlevel=0;for(;j<m;j++){l=j;if(-1==f.substr(j).indexOf("<")){h+=f.substr(j);return this.cleanFinish(h);}while(l<m&&f.charAt(l)!="<"){l++;}if(j!=l){o=f.substr(j,l-j);if(!o.match(/^\s{2,}$/g)){if("\n"==h.charAt(h.length-1)){h+=this.cleanGetTabs();}else{if("\n"==o.charAt(0)){h+="\n"+this.cleanGetTabs();o=o.replace(/^\s+/,"");}}h+=o;}if(o.match(/\n/)){h+="\n"+this.cleanGetTabs();}}e=l;while(l<m&&">"!=f.charAt(l)){l++;}p=f.substr(e,l-e);j=l;var n;if("!--"==p.substr(1,3)){if(!p.match(/--$/)){while("-->"!=f.substr(l,3)){l++;}l+=2;p=f.substr(e,l-e);j=l;}if("\n"!=h.charAt(h.length-1)){h+="\n";}h+=this.cleanGetTabs();h+=p+">\n";}else{if("!"==p[1]){h=this.placeTag(p+">",h);}else{if("?"==p[1]){h+=p+">\n";}else{if(n=p.match(/^<(script|style|pre)/i)){n[1]=n[1].toLowerCase();p=this.cleanTag(p);h=this.placeTag(p,h);g=String(f.substr(j+1)).toLowerCase().indexOf("</"+n[1]);if(g){o=f.substr(j+1,g);j+=g;h+=o;}}else{p=this.cleanTag(p);h=this.placeTag(p,h);}}}}}return this.cleanFinish(h);},cleanGetTabs:function(){var f="";for(var e=0;e<this.cleanlevel;e++){f+="\t";}return f;},cleanFinish:function(e){e=e.replace(/\n\s*\n/g,"\n");e=e.replace(/^[\s\n]*/,"");e=e.replace(/[\s\n]*$/,"");e=e.replace(/<script(.*?)>\n<\/script>/gi,"<script$1><\/script>");this.cleanlevel=0;return e;},cleanTag:function(f){var h="";f=f.replace(/\n/g," ");f=f.replace(/\s{2,}/g," ");f=f.replace(/^\s+|\s+$/g," ");var g="";if(f.match(/\/$/)){g="/";f=f.replace(/\/+$/,"");}var e;while(e=/\s*([^= ]+)(?:=((['"']).*?\3|[^ ]+))?/.exec(f)){if(e[2]){h+=e[1].toLowerCase()+"="+e[2];}else{if(e[1]){h+=e[1].toLowerCase();}}h+=" ";f=f.substr(e[0].length);}return h.replace(/\s*$/,"")+g+">";},placeTag:function(e,g){var f=e.match(this.cleannewLevel);if(e.match(this.cleanlineBefore)||f){g=g.replace(/\s*$/,"");g+="\n";}if(f&&"/"==e.charAt(1)){this.cleanlevel--;}if("\n"==g.charAt(g.length-1)){g+=this.cleanGetTabs();}if(f&&"/"!=e.charAt(1)){this.cleanlevel++;}g+=e;if(e.match(this.cleanlineAfter)||e.match(this.cleannewLevel)){g=g.replace(/ *$/,"");g+="\n";}return g;},formatEmpty:function(i){var f=c.trim(this.$editor.html());f=f.replace(/<br\s?\/?>/i,"");var h=f.replace(/<p>\s?<\/p>/gi,"");if(f===""||h===""){i.preventDefault();var g=c(this.opts.emptyHtml).get(0);this.$editor.html(g);this.focus();}this.sync();},formatBlocks:function(e){this.bufferSet();var f=this.getBlocks();this.selectionSave();c.each(f,c.proxy(function(g,h){if(h.tagName!=="LI"){this.formatBlock(e,h);}},this));this.selectionRestore();this.sync();},formatBlock:function(e,h){if(h===false){h=this.getBlock();}if(h===false){if(this.opts.linebreaks===true){this.execCommand("formatblock",e);}return true;}var g="";if(e!=="pre"){g=c(h).contents();}else{g=c(h).html();if(c.trim(g)===""){g='<span id="selection-marker-1"></span>';}}if(h.tagName==="PRE"){e="p";}if(this.opts.linebreaks===true&&e==="p"){c(h).replaceWith(c("<div>").append(g).html()+"<br>");}else{var f=c("<"+e+">").append(g);c(h).replaceWith(f);}},formatChangeTag:function(g,e,f){if(f!==false){this.selectionSave();}var h=c("<"+e+"/>");c(g).replaceWith(function(){return h.append(c(this).contents());});if(f!==false){this.selectionRestore();}return h;},formatQuote:function(){this.bufferSet();if(this.opts.linebreaks===false){this.selectionSave();var j=this.getBlocks();if(j){c.each(j,c.proxy(function(m,n){if(n.tagName==="BLOCKQUOTE"){this.formatBlock("p",n,false);}else{if(n.tagName!=="LI"){this.formatBlock("blockquote",n,false);}}},this));}this.selectionRestore();}else{var i=this.getBlock();if(i.tagName==="BLOCKQUOTE"){this.selectionSave();c(i).replaceWith(c(i).html()+"<br>");this.selectionRestore();}else{var l=this.selectionWrap("blockquote");var g=c(l).html();var f=["ul","ol","table","tr","tbody","thead","tfoot","dl"];c.each(f,function(m,n){g=g.replace(new RegExp("<"+n+"(.*?)>","gi"),"");g=g.replace(new RegExp("</"+n+">","gi"),"");});var e=this.opts.blockLevelElements;e.push("td");c.each(e,function(m,n){g=g.replace(new RegExp("<"+n+"(.*?)>","gi"),"");g=g.replace(new RegExp("</"+n+">","gi"),"<br>");});c(l).html(g);this.selectionElement(l);var h=c(l).next();if(h.size()!=0&&h[0].tagName==="BR"){h.remove();}}}this.sync();},blockRemoveAttr:function(e,g){var f=this.getBlocks();c(f).removeAttr(e);this.sync();},blockSetAttr:function(e,g){var f=this.getBlocks();c(f).attr(e,g);this.sync();},blockRemoveStyle:function(f){var e=this.getBlocks();c(e).css(f,"");this.removeEmptyAttr(e,"style");this.sync();},blockSetStyle:function(g,f){var e=this.getBlocks();c(e).css(g,f);this.sync();},blockRemoveClass:function(f){var e=this.getBlocks();c(e).removeClass(f);this.removeEmptyAttr(e,"class");this.sync();},blockSetClass:function(f){var e=this.getBlocks();c(e).addClass(f);this.sync();},inlineRemoveClass:function(e){this.selectionSave();this.inlineEachNodes(function(f){c(f).removeClass(e);this.removeEmptyAttr(f,"class");});this.selectionRestore();this.sync();},inlineSetClass:function(e){var f=this.getCurrent();if(!c(f).hasClass(e)){this.inlineMethods("addClass",e);}},inlineRemoveStyle:function(e){this.selectionSave();this.inlineEachNodes(function(f){c(f).css(e,"");this.removeEmptyAttr(f,"style");});this.selectionRestore();this.sync();},inlineSetStyle:function(f,e){this.inlineMethods("css",f,e);},inlineRemoveAttr:function(e){this.selectionSave();var g=this.getRange(),h=this.getElement(),f=this.getNodes();if(g.collapsed||g.startContainer===g.endContainer&&h){f=c(h);}c(f).removeAttr(e);this.inlineUnwrapSpan();this.selectionRestore();this.sync();},inlineSetAttr:function(e,f){this.inlineMethods("attr",e,f);},inlineMethods:function(h,e,i){this.bufferSet();this.selectionSave();var f=this.getRange();var g=this.getElement();if((f.collapsed||f.startContainer===f.endContainer)&&g&&!this.nodeTestBlocks(g)){c(g)[h](e,i);}else{this.document.execCommand("fontSize",false,4);var j=this.$editor.find("font");c.each(j,c.proxy(function(l,m){this.inlineSetMethods(h,m,e,i);},this));}this.selectionRestore();this.sync();},inlineSetMethods:function(i,h,e,j){var g=c(h).parent(),f;if(g&&g[0].tagName==="INLINE"&&g[0].attributes.length!=0){f=g;c(h).replaceWith(c(h).html());}else{f=c("<inline>").append(c(h).contents());c(h).replaceWith(f);}c(f)[i](e,j);return f;},inlineEachNodes:function(i){var f=this.getRange(),g=this.getElement(),e=this.getNodes(),h;if(f.collapsed||f.startContainer===f.endContainer&&g){e=c(g);h=true;}c.each(e,c.proxy(function(j,l){if(!h&&l.tagName!=="INLINE"){if(l.parentNode.tagName==="INLINE"&&!c(l.parentNode).hasClass("redactor_editor")){l=l.parentNode;}else{return;}}i.call(this,l);},this));},inlineUnwrapSpan:function(){var e=this.$editor.find("inline");c.each(e,c.proxy(function(g,h){var f=c(h);if(f.attr("class")===undefined&&f.attr("style")===undefined){f.contents().unwrap();}},this));},inlineFormat:function(e){this.selectionSave();this.document.execCommand("fontSize",false,4);var g=this.$editor.find("font");var f;c.each(g,function(h,l){var j=c("<"+e+"/>").append(c(l).contents());c(l).replaceWith(j);f=j;});this.selectionRestore();this.sync();},inlineRemoveFormat:function(e){this.selectionSave();var f=e.toUpperCase();var g=this.getNodes();var h=c(this.getParent()).parent();c.each(g,function(j,l){if(l.tagName===f){this.inlineRemoveFormatReplace(l);}});if(h&&h[0].tagName===f){this.inlineRemoveFormatReplace(h);}this.selectionRestore();this.sync();},inlineRemoveFormatReplace:function(e){c(e).replaceWith(c(e).contents());},insertHtml:function(g,i){var l=this.getCurrent();var h=l.parentNode;this.$editor.focus();this.bufferSet();var e=c("<div>").append(c.parseHTML(g));g=e.html();g=this.cleanRemoveEmptyTags(g);e=c("<div>").append(c.parseHTML(g));var f=this.getBlock();if(e.contents().length==1){var j=e.contents()[0].tagName;if(j!="P"&&j==f.tagName||j=="PRE"){g=e.text();e=c("<div>").append(g);}}if(!this.opts.linebreaks&&e.contents().length==1&&e.contents()[0].nodeType==3&&(this.getRangeSelectedNodes().length>2||(!l||l.tagName=="BODY"&&!h||h.tagName=="HTML"))){g="<p>"+g+"</p>";}g=this.setSpansVerifiedHtml(g);if(e.contents().length>1&&f||e.contents().is("p, :header, ul, ol, div, table, blockquote, pre, address, section, header, footer, aside, article")){if(this.browser("msie")){this.document.selection.createRange().pasteHTML(g);}else{this.document.execCommand("inserthtml",false,g);}}else{this.insertHtmlAdvanced(g,false);}if(this.selectall){this.window.setTimeout(c.proxy(function(){if(!this.opts.linebreaks){this.selectionEnd(this.$editor.contents().last());}else{this.focusEnd();}},this),1);}this.observeStart();this.setNonEditable();if(i!==false){this.sync();}},insertHtmlAdvanced:function(f,j){var l=this.getSelection();if(l.getRangeAt&&l.rangeCount){var e=l.getRangeAt(0);e.deleteContents();var g=this.document.createElement("div");g.innerHTML=f;var m=this.document.createDocumentFragment(),i,h;while((i=g.firstChild)){h=m.appendChild(i);}e.insertNode(m);if(h){e=e.cloneRange();e.setStartAfter(h);e.collapse(true);l.removeAllRanges();l.addRange(e);}}if(j!==false){this.sync();}},insertText:function(f){var e=c(c.parseHTML(f));if(e.length){f=e.text();}this.$editor.focus();if(this.browser("msie")){this.document.selection.createRange().pasteHTML(f);}else{this.document.execCommand("inserthtml",false,f);}this.sync();},insertNode:function(e){e=e[0]||e;var f=this.getSelection();if(f.getRangeAt&&f.rangeCount){range=f.getRangeAt(0);range.deleteContents();range.insertNode(e);range.setEndAfter(e);range.setStartAfter(e);f.removeAllRanges();f.addRange(range);}},insertNodeToCaretPositionFromPoint:function(j,i){var g;var f=j.clientX,m=j.clientY;if(this.document.caretPositionFromPoint){var l=this.document.caretPositionFromPoint(f,m);g=this.getRange();g.setStart(l.offsetNode,l.offset);g.collapse(true);g.insertNode(i);}else{if(this.document.caretRangeFromPoint){g=this.document.caretRangeFromPoint(f,m);g.insertNode(i);}else{if(typeof document.body.createTextRange!="undefined"){g=this.document.body.createTextRange();g.moveToPoint(f,m);var h=g.duplicate();h.moveToPoint(f,m);g.setEndPoint("EndToEnd",h);g.select();}}}},insertAfterLastElement:function(e){if(this.isEndOfElement()){if(c(c.trim(this.$editor.html())).get(0)!=c.trim(e)&&this.$editor.contents().last()[0]!==e){return false;}this.bufferSet();if(this.opts.linebreaks===false){var f=c(this.opts.emptyHtml);c(e).after(f);this.selectionStart(f);}else{var f=c('<span id="selection-marker-1">'+this.opts.invisibleSpace+"</span>",this.document)[0];c(e).after(f);c(f).after(this.opts.invisibleSpace);this.selectionRestore();}}},insertLineBreak:function(){this.selectionSave();this.$editor.find("#selection-marker-1").before("<br>"+(this.browser("webkit")?this.opts.invisibleSpace:""));this.selectionRestore();},insertDoubleLineBreak:function(){this.selectionSave();this.$editor.find("#selection-marker-1").before("<br><br>"+(this.browser("webkit")?this.opts.invisibleSpace:""));this.selectionRestore();},replaceLineBreak:function(e){var f=c("<br>"+this.opts.invisibleSpace);c(e).replaceWith(f);this.selectionStart(f);},pasteClean:function(g){g=this.callback("pasteBefore",false,g);if(this.opts.pastePlainText){var f=this.document.createElement("div");g=g.replace(/<br>|<\/H[1-6]>|<\/p>|<\/div>/gi,"\n");f.innerHTML=g;g=f.textContent||f.innerText;g=c.trim(g);g=g.replace("\n","<br>");g=this.cleanParagraphy(g);this.pasteInsert(g);return false;}if(this.currentOrParentIs("PRE")){g=this.pastePre(g);this.pasteInsert(g);return true;}g=g.replace(/<p(.*?)class="MsoListParagraphCxSpFirst"([\w\W]*?)<\/p>/gi,"<ul><li$2</li>");g=g.replace(/<p(.*?)class="MsoListParagraphCxSpMiddle"([\w\W]*?)<\/p>/gi,"<li$2</li>");g=g.replace(/<p(.*?)class="MsoListParagraphCxSpLast"([\w\W]*?)<\/p>/gi,"<li$2</li></ul>");g=g.replace(/<p(.*?)class="MsoListParagraph"([\w\W]*?)<\/p>/gi,"<ul><li$2</li></ul>");g=g.replace(/·/g,"");g=g.replace(/<!--[\s\S]*?-->|<\?(?:php)?[\s\S]*?\?>/gi,"");g=g.replace(/(&nbsp;){2,}/gi,"&nbsp;");g=g.replace(/&nbsp;/gi," ");g=g.replace(/<b\sid="internal-source-marker(.*?)">([\w\W]*?)<\/b>/gi,"$2");g=g.replace(/<b(.*?)id="docs-internal-guid(.*?)">([\w\W]*?)<\/b>/gi,"$3");g=this.cleanStripTags(g);g=g.replace(/<td><\/td>/gi,"[td]");g=g.replace(/<td>&nbsp;<\/td>/gi,"[td]");g=g.replace(/<td><br><\/td>/gi,"[td]");g=g.replace(/<td(.*?)colspan="(.*?)"(.*?)>([\w\W]*?)<\/td>/gi,'[td colspan="$2"]$4[/td]');g=g.replace(/<a(.*?)href="(.*?)"(.*?)>([\w\W]*?)<\/a>/gi,'[a href="$2"]$4[/a]');g=g.replace(/<iframe(.*?)>([\w\W]*?)<\/iframe>/gi,"[iframe$1]$2[/iframe]");g=g.replace(/<video(.*?)>([\w\W]*?)<\/video>/gi,"[video$1]$2[/video]");g=g.replace(/<audio(.*?)>([\w\W]*?)<\/audio>/gi,"[audio$1]$2[/audio]");g=g.replace(/<embed(.*?)>([\w\W]*?)<\/embed>/gi,"[embed$1]$2[/embed]");g=g.replace(/<object(.*?)>([\w\W]*?)<\/object>/gi,"[object$1]$2[/object]");g=g.replace(/<param(.*?)>/gi,"[param$1]");g=g.replace(/<img(.*?)>/gi,"[img$1]");g=g.replace(/ class="(.*?)"/gi,"");g=g.replace(/<(\w+)([\w\W]*?)>/gi,"<$1>");g=g.replace(/<[^\/>][^>]*>(\s*|\t*|\n*|&nbsp;|<br>)<\/[^>]+>/gi,"");g=g.replace(/<div>\s*?\t*?\n*?(<ul>|<ol>|<p>)/gi,"$1");g=g.replace(/\[td colspan="(.*?)"\]([\w\W]*?)\[\/td\]/gi,'<td colspan="$1">$2</td>');g=g.replace(/\[td\]/gi,"<td>&nbsp;</td>");g=g.replace(/\[a href="(.*?)"\]([\w\W]*?)\[\/a\]/gi,'<a href="$1">$2</a>');g=g.replace(/\[iframe(.*?)\]([\w\W]*?)\[\/iframe\]/gi,"<iframe$1>$2</iframe>");g=g.replace(/\[video(.*?)\]([\w\W]*?)\[\/video\]/gi,"<video$1>$2</video>");g=g.replace(/\[audio(.*?)\]([\w\W]*?)\[\/audio\]/gi,"<audio$1>$2</audio>");g=g.replace(/\[embed(.*?)\]([\w\W]*?)\[\/embed\]/gi,"<embed$1>$2</embed>");g=g.replace(/\[object(.*?)\]([\w\W]*?)\[\/object\]/gi,"<object$1>$2</object>");g=g.replace(/\[param(.*?)\]/gi,"<param$1>");g=g.replace(/\[img(.*?)\]/gi,"<img$1>");if(this.opts.convertDivs){g=g.replace(/<div(.*?)>([\w\W]*?)<\/div>/gi,"<p>$2</p>");g=g.replace(/<\/div><p>/gi,"<p>");g=g.replace(/<\/p><\/div>/gi,"</p>");}if(this.currentOrParentIs("LI")){g=g.replace(/<p>([\w\W]*?)<\/p>/gi,"$1<br>");}else{g=this.cleanParagraphy(g);}g=g.replace(/<span(.*?)>([\w\W]*?)<\/span>/gi,"$2");g=g.replace(/<img>/gi,"");g=g.replace(/<[^\/>][^>][^img|param|source]*>(\s*|\t*|\n*|&nbsp;|<br>)<\/[^>]+>/gi,"");g=g.replace(/\n{3,}/gi,"\n");g=g.replace(/<p><p>/gi,"<p>");g=g.replace(/<\/p><\/p>/gi,"</p>");g=g.replace(/<li>(\s*|\t*|\n*)<p>/gi,"<li>");g=g.replace(/<\/p>(\s*|\t*|\n*)<\/li>/gi,"</li>");if(this.opts.linebreaks===true){g=g.replace(/<p(.*?)>([\w\W]*?)<\/p>/gi,"$2<br>");}g=g.replace(/<[^\/>][^>][^img|param|source]*>(\s*|\t*|\n*|&nbsp;|<br>)<\/[^>]+>/gi,"");g=g.replace(/<img src="webkit-fake-url\:\/\/(.*?)"(.*?)>/gi,"");g=g.replace(/<td(.*?)>(\s*|\t*|\n*)<p>([\w\W]*?)<\/p>(\s*|\t*|\n*)<\/td>/gi,"<td$1>$3</td>");g=g.replace(/<div(.*?)>([\w\W]*?)<\/div>/gi,"$2");g=g.replace(/<div(.*?)>([\w\W]*?)<\/div>/gi,"$2");this.pasteClipboardMozilla=false;if(this.browser("mozilla")){if(this.opts.clipboardUpload){var h=g.match(/<img src="data:image(.*?)"(.*?)>/gi);if(h!==null){this.pasteClipboardMozilla=h;for(k in h){var e=h[k].replace("<img",'<img data-mozilla-paste-image="'+k+'" ');g=g.replace(h[k],e);}}}while(/<br>$/gi.test(g)){g=g.replace(/<br>$/gi,"");}}g=g.replace(/<p>•([\w\W]*?)<\/p>/gi,"<li>$1</li>");while(/<font>([\w\W]*?)<\/font>/gi.test(g)){g=g.replace(/<font>([\w\W]*?)<\/font>/gi,"$1");}this.pasteInsert(g);},pastePre:function(f){f=f.replace(/<br>|<\/H[1-6]>|<\/p>|<\/div>/gi,"\n");var e=this.document.createElement("div");e.innerHTML=f;return this.cleanEncodeEntities(e.textContent||e.innerText);},pasteInsert:function(e){if(this.selectall){if(!this.opts.linebreaks){this.$editor.html(this.opts.emptyHtml);}else{this.$editor.html("");}this.$editor.focus();}e=this.callback("pasteAfter",false,e);this.insertHtml(e);this.selectall=false;setTimeout(c.proxy(function(){this.rtePaste=false;if(this.browser("mozilla")){this.$editor.find("p:empty").remove();}if(this.pasteClipboardMozilla!==false){this.pasteClipboardUploadMozilla();}},this),100);if(this.opts.autoresize){c(this.document.body).scrollTop(this.saveScroll);}else{this.$editor.scrollTop(this.saveScroll);}},pasteClipboardUploadMozilla:function(){var e=this.$editor.find("img[data-mozilla-paste-image]");c.each(e,c.proxy(function(h,j){var g=c(j);var f=j.src.split(",");var l=f[1];var m=f[0].split(";")[0].split(":")[1];c.post(this.opts.clipboardUploadUrl,{contentType:m,data:l},c.proxy(function(n){var i=(typeof n==="string"?c.parseJSON(n):n);g.attr("src",i.filelink);g.removeAttr("data-mozilla-paste-image");this.sync();this.callback("imageUpload",g,i);},this));},this));},pasteClipboardUpload:function(i){var g=i.target.result;var f=g.split(",");var h=f[1];var j=f[0].split(";")[0].split(":")[1];if(this.opts.clipboardUpload){c.post(this.opts.clipboardUploadUrl,{contentType:j,data:h},c.proxy(function(m){var l=(typeof m==="string"?c.parseJSON(m):m);var e='<img src="'+l.filelink+'" id="clipboard-image-marker" />';this.execCommand("inserthtml",e,false);var n=c(this.$editor.find("img#clipboard-image-marker"));if(n.length){n.removeAttr("id");}else{n=false;}this.sync();if(n){this.callback("imageUpload",n,l);}},this));}else{this.insertHtml('<img src="'+g+'" />');}},bufferSet:function(e){if(e!==undefined){this.opts.buffer.push(e);}else{this.selectionSave();this.opts.buffer.push(this.$editor.html());this.selectionRemoveMarkers("buffer");}},bufferUndo:function(){if(this.opts.buffer.length===0){this.$editor.focus();return;}this.selectionSave();this.opts.rebuffer.push(this.$editor.html());this.selectionRestore(false,true);this.$editor.html(this.opts.buffer.pop());this.selectionRestore();setTimeout(c.proxy(this.observeStart,this),100);},bufferRedo:function(){if(this.opts.rebuffer.length===0){this.$editor.focus();return false;}this.selectionSave();this.opts.buffer.push(this.$editor.html());this.selectionRestore(false,true);this.$editor.html(this.opts.rebuffer.pop());this.selectionRestore(true);setTimeout(c.proxy(this.observeStart,this),4);},observeStart:function(){this.observeImages();if(this.opts.observeLinks){this.observeLinks();}},observeLinks:function(){this.$editor.find("a").on("click",c.proxy(this.linkObserver,this));this.$editor.on("click.redactor",c.proxy(function(f){this.linkObserverTooltipClose(f);},this));},observeImages:function(){if(this.opts.observeImages===false){return false;}this.$editor.find("img").each(c.proxy(function(e,f){if(this.browser("msie")){c(f).attr("unselectable","on");}this.imageResize(f);},this));},linkObserver:function(h){var i=c(h.target);var l=i.offset();if(this.opts.iframe){var g=this.$frame.offset();l.top=g.top+(l.top-c(this.document).scrollTop());l.left+=g.left;}var o=c('<span class="redactor-link-tooltip"></span>');var f=i.attr("href");if(f.length>24){f=f.substring(0,24)+"...";}var j=c('<a href="'+i.attr("href")+'" target="_blank">'+f+"</a>").on("click",c.proxy(function(p){this.linkObserverTooltipClose(false);},this));var m=c('<a href="#">'+this.opts.curLang.edit+"</a>").on("click",c.proxy(function(p){p.preventDefault();this.linkShow();this.linkObserverTooltipClose(false);},this));var n=c('<a href="#">'+this.opts.curLang.unlink+"</a>").on("click",c.proxy(function(p){p.preventDefault();this.execCommand("unlink");this.linkObserverTooltipClose(false);},this));o.append(j);o.append(" | ");o.append(m);o.append(" | ");o.append(n);o.css({top:(l.top+20)+"px",left:l.left+"px"});c(".redactor-link-tooltip").remove();c("body").append(o);},linkObserverTooltipClose:function(f){if(f!==false&&f.target.tagName=="A"){return false;}c(".redactor-link-tooltip").remove();},getSelection:function(){if(!this.opts.rangy){return this.document.getSelection();}else{if(!this.opts.iframe){return rangy.getSelection();}else{return rangy.getSelection(this.$frame[0]);}}},getRange:function(){if(!this.opts.rangy){if(this.document.getSelection){var e=this.getSelection();if(e.getRangeAt&&e.rangeCount){return e.getRangeAt(0);}}return this.document.createRange();}else{if(!this.opts.iframe){return rangy.createRange();}else{return rangy.createRange(this.iframeDoc());}}},selectionElement:function(e){this.setCaret(e);},selectionStart:function(e){this.selectionSet(e[0]||e,0,null,0);},selectionEnd:function(e){this.selectionSet(e[0]||e,1,null,1);},selectionSet:function(m,l,j,h){if(j==null){j=m;}if(h==null){h=l;}var g=this.getSelection();if(!g){return;}var f=this.getRange();f.setStart(m,l);f.setEnd(j,h);try{g.removeAllRanges();}catch(i){}g.addRange(f);},selectionWrap:function(e){e=e.toLowerCase();var h=this.getBlock();if(h){var i=this.formatChangeTag(h,e);this.sync();return i;}var g=this.getSelection();var f=g.getRangeAt(0);var i=document.createElement(e);i.appendChild(f.extractContents());f.insertNode(i);this.selectionElement(i);return i;},selectionAll:function(){var e=this.getRange();e.selectNodeContents(this.$editor[0]);var f=this.getSelection();f.removeAllRanges();f.addRange(e);},selectionRemove:function(){this.getSelection().removeAllRanges();},getCaretOffset:function(h){var e=0;var g=this.getRange();var f=g.cloneRange();f.selectNodeContents(h);f.setEnd(g.endContainer,g.endOffset);e=c.trim(f.toString()).length;return e;},getCaretOffsetRange:function(){return new d(this.getSelection().getRangeAt(0));},setCaret:function(h,f,m){if(typeof m==="undefined"){m=f;}h=h[0]||h;var o=this.getRange();o.selectNodeContents(h);var p=this.getTextNodesIn(h);var l=false;var e=0,q;if(p.length==1&&f){o.setStart(p[0],f);o.setEnd(p[0],m);}else{for(var n=0,j;j=p[n++];){q=e+j.length;if(!l&&f>=e&&(f<q||(f==q&&n<p.length))){o.setStart(j,f-e);l=true;}if(l&&m<=q){o.setEnd(j,m-e);break;}e=q;}}var g=this.getSelection();g.removeAllRanges();g.addRange(o);},getTextNodesIn:function(j){var h=[];if(j.nodeType==3){h.push(j);}else{var g=j.childNodes;for(var f=0,e=g.length;f<e;++f){h.push.apply(h,this.getTextNodesIn(g[f]));}}return h;},getCurrent:function(){var e=false;var f=this.getSelection();if(f.rangeCount>0){e=f.getRangeAt(0).startContainer;}return this.isParentRedactor(e);},getParent:function(e){e=e||this.getCurrent();if(e){return this.isParentRedactor(c(e).parent()[0]);}else{return false;}},getBlock:function(e){if(typeof e==="undefined"){e=this.getCurrent();}while(e){if(this.nodeTestBlocks(e)){if(c(e).hasClass("redactor_editor")){return false;}return e;}e=e.parentNode;}return false;},getBlocks:function(f){var g=[];if(typeof f=="undefined"){var e=this.getRange();if(e&&e.collapsed===true){return[this.getBlock()];}var f=this.getNodes(e);}c.each(f,c.proxy(function(h,j){if(this.opts.iframe===false&&c(j).parents("div.redactor_editor").size()==0){return false;}if(this.nodeTestBlocks(j)){g.push(j);}},this));if(g.length===0){g=[this.getBlock()];}return g;},nodeTestBlocks:function(e){return e.nodeType==1&&this.rTestBlock.test(e.nodeName);},tagTestBlock:function(e){return this.rTestBlock.test(e);},getSelectedNodes:function(j){if(typeof j=="undefined"||j==false){var j=this.getRange();}if(j&&j.collapsed===true){return[this.getCurrent()];}var f=this.getSelection();try{var p=f.getRangeAt(0).cloneContents();}catch(n){return(false);}var l=this.document.createElement("span");l.appendChild(p);window.selnodes=l.childNodes;var m=selnodes.length;var g=[];for(var h=0,o=m;h<o;h++){g.push(selnodes[h]);}if(g.length==0){g.push(this.getCurrent());}return g;},getNodes:function(g,e){if(this.opts.linebreaks){return this.getSelectedNodes(g);}if(typeof g=="undefined"||g==false){var g=this.getRange();}if(g&&g.collapsed===true){if(typeof e==="undefined"&&this.tagTestBlock(e)){var j=this.getBlock();if(j.tagName==e){return[j];}else{return[];}}else{return[this.getCurrent()];}}var f=[],i=[];var h=this.document.getSelection();if(!h.isCollapsed){f=this.getRangeSelectedNodes(h.getRangeAt(0));}c.each(f,c.proxy(function(l,m){if(this.opts.iframe===false&&c(m).parents("div.redactor_editor").size()==0){return false;}if(typeof e==="undefined"){if(c.trim(m.textContent)!=""){i.push(m);}}else{if(m.tagName==e){i.push(m);}}},this));if(i.length==0){if(typeof e==="undefined"&&this.tagTestBlock(e)){var j=this.getBlock();if(j.tagName==e){return i.push(j);}else{return[];}}else{i.push(this.getCurrent());}}return i;},getElement:function(e){if(!e){e=this.getCurrent();}while(e){if(e.nodeType==1){if(c(e).hasClass("redactor_editor")){return false;}return e;}e=e.parentNode;}return false;},getRangeSelectedNodes:function(f){f=f||this.getRange();var g=f.startContainer;var e=f.endContainer;if(g==e){return[g];}var h=[];while(g&&g!=e){h.push(g=this.nextNode(g));}g=f.startContainer;while(g&&g!=f.commonAncestorContainer){h.unshift(g);g=g.parentNode;}return h;},nextNode:function(e){if(e.hasChildNodes()){return e.firstChild;}else{while(e&&!e.nextSibling){e=e.parentNode;}if(!e){return null;}return e.nextSibling;}},getSelectionText:function(){return this.getSelection().toString();},getSelectionHtml:function(){var h="";var j=this.getSelection();if(j.rangeCount){var f=this.document.createElement("div");var e=j.rangeCount;for(var g=0;g<e;++g){f.appendChild(j.getRangeAt(g).cloneContents());}h=f.innerHTML;}return this.syncClean(h);},selectionSave:function(){if(!this.isFocused()){this.$editor.focus();}if(!this.opts.rangy){this.selectionCreateMarker(this.getRange());}else{this.savedSel=rangy.saveSelection();}},selectionCreateMarker:function(h,e){if(!h){return;}var g=c('<span id="selection-marker-1" class="redactor-selection-marker">'+this.opts.invisibleSpace+"</span>",this.document)[0];var f=c('<span id="selection-marker-2" class="redactor-selection-marker">'+this.opts.invisibleSpace+"</span>",this.document)[0];if(h.collapsed===true){this.selectionSetMarker(h,g,true);}else{this.selectionSetMarker(h,g,true);this.selectionSetMarker(h,f,false);}this.savedSel=this.$editor.html();this.selectionRestore(false,false);},selectionSetMarker:function(e,g,f){var h=e.cloneRange();h.collapse(f);h.insertNode(g);h.detach();},selectionRestore:function(h,e){if(!this.opts.rangy){if(h===true&&this.savedSel){this.$editor.html(this.savedSel);}var g=this.$editor.find("span#selection-marker-1");var f=this.$editor.find("span#selection-marker-2");if(this.browser("mozilla")){this.$editor.focus();}else{if(!this.isFocused()){this.$editor.focus();}}if(g.length!=0&&f.length!=0){this.selectionSet(g[0],0,f[0],0);}else{if(g.length!=0){this.selectionSet(g[0],0,null,0);}}if(e!==false){this.selectionRemoveMarkers();this.savedSel=false;}}else{rangy.restoreSelection(this.savedSel);}},selectionRemoveMarkers:function(e){if(!this.opts.rangy){c.each(this.$editor.find("span.redactor-selection-marker"),function(){var f=c.trim(c(this).html().replace(/[^\u0000-\u1C7F]/g,""));if(f==""){c(this).remove();}else{c(this).removeAttr("class").removeAttr("id");}});}else{rangy.removeMarkers(this.savedSel);}},tableShow:function(){this.selectionSave();this.modalInit(this.opts.curLang.table,this.opts.modal_table,300,c.proxy(function(){c("#redactor_insert_table_btn").click(c.proxy(this.tableInsert,this));setTimeout(function(){c("#redactor_table_rows").focus();},200);},this));},tableInsert:function(){var r=c("#redactor_table_rows").val(),f=c("#redactor_table_columns").val(),n=c("<div></div>"),e=Math.floor(Math.random()*99999),p=c('<table id="table'+e+'"><tbody></tbody></table>'),g,l,m,o;for(g=0;g<r;g++){l=c("<tr></tr>");for(m=0;m<f;m++){o=c("<td>"+this.opts.invisibleSpace+"</td>");if(g===0&&m===0){o.append('<span id="selection-marker-1">'+this.opts.invisibleSpace+"</span>");}c(l).append(o);}p.append(l);}n.append(p);var h=n.html();this.modalClose();this.selectionRestore();var j=this.getBlock()||this.getCurrent();if(j&&j.tagName!="BODY"){c(j).after(h);}else{this.insertHtmlAdvanced(h,false);}this.selectionRestore();var q=this.$editor.find("#table"+e);this.buttonActiveObserver();q.find("span#selection-marker-1").remove();q.removeAttr("id");this.sync();},tableDeleteTable:function(){var e=c(this.getParent()).closest("table");if(e.size()==0){return false;}this.bufferSet();e.remove();this.sync();},tableDeleteRow:function(){var e=c(this.getParent()).closest("table");if(e.size()==0){return false;}this.bufferSet();var h=c(this.getParent()).closest("tr");var f=h.prev().length?h.prev():h.next();if(f.length){var g=f.children("td").first();if(g.length){g.prepend('<span id="selection-marker-1">'+this.opts.invisibleSpace+"</span>");}}h.remove();this.selectionRestore();this.sync();},tableDeleteColumn:function(){var g=c(this.getParent()).closest("table");if(g.size()==0){return false;}this.bufferSet();var e=c(this.getParent()).closest("td");var f=e.get(0).cellIndex;g.find("tr").each(c.proxy(function(h,j){var l=f-1<0?f+1:f-1;if(h===0){c(j).find("td").eq(l).prepend('<span id="selection-marker-1">'+this.opts.invisibleSpace+"</span>");}c(j).find("td").eq(f).remove();},this));this.selectionRestore();this.sync();},tableAddHead:function(){var e=c(this.getParent()).closest("table");if(e.size()==0){return false;}this.bufferSet();if(e.find("thead").size()!==0){this.tableDeleteHead();}else{var f=e.find("tr").first().clone();f.find("td").html(this.opts.invisibleSpace);$thead=c("<thead></thead>");$thead.append(f);e.prepend($thead);this.sync();}},tableDeleteHead:function(){var e=c(this.getParent()).closest("table");var f=e.find("thead");if(f.size()==0){return false;}this.bufferSet();f.remove();this.sync();},tableAddRowAbove:function(){this.tableAddRow("before");},tableAddRowBelow:function(){this.tableAddRow("after");},tableAddColumnLeft:function(){this.tableAddColumn("before");},tableAddColumnRight:function(){this.tableAddColumn("after");},tableAddRow:function(f){var e=c(this.getParent()).closest("table");if(e.size()==0){return false;}this.bufferSet();var g=c(this.getParent()).closest("tr");var h=g.clone();h.find("td").html(this.opts.invisibleSpace);if(f==="after"){g.after(h);}else{g.before(h);}this.sync();},tableAddColumn:function(h){var g=c(this.getParent()).closest("table");if(g.size()==0){return false;}this.bufferSet();var f=0;var i=c(this.getParent()).closest("tr");var e=c(this.getParent()).closest("td");i.find("td").each(c.proxy(function(j,l){if(c(l)[0]===e[0]){f=j;}},this));g.find("tr").each(c.proxy(function(j,m){var l=c(m).find("td").eq(f);var n=l.clone();n.html(this.opts.invisibleSpace);h==="after"?l.after(n):l.before(n);},this));this.sync();},videoShow:function(){this.selectionSave();this.modalInit(this.opts.curLang.video,this.opts.modal_video,600,c.proxy(function(){c("#redactor_insert_video_btn").click(c.proxy(this.videoInsert,this));setTimeout(function(){c("#redactor_insert_video_area").focus();},200);},this));},videoInsert:function(){var e=c("#redactor_insert_video_area").val();e=this.cleanStripTags(e);this.selectionRestore();var f=this.getBlock()||this.getCurrent();if(f){c(f).after(e);}else{this.insertHtmlAdvanced(e,false);}this.sync();this.modalClose();},linkShow:function(){this.selectionSave();var e=c.proxy(function(){this.insert_link_node=false;var g=this.getSelection();var f="",n="",i="";var h=this.getParent();var j=c(h).parent().get(0);if(j&&j.tagName==="A"){h=j;}if(h&&h.tagName==="A"){f=h.href;n=c(h).text();i=h.target;this.insert_link_node=h;}else{n=g.toString();}c(".redactor_link_text").val(n);var p=self.location.href.replace(/\/$/i,"");var m=f.replace(p,"");if(this.opts.linkProtocol===false){var o=new RegExp("^(http|ftp|https)://"+self.location.host,"i");m=m.replace(o,"");}var l=c("#redactor_tabs").find("a");if(this.opts.linkEmail===false){l.eq(1).remove();}if(this.opts.linkAnchor===false){l.eq(2).remove();}if(this.opts.linkEmail===false&&this.opts.linkAnchor===false){c("#redactor_tabs").remove();c("#redactor_link_url").val(m);}else{if(f.search("mailto:")===0){this.modalSetTab.call(this,2);c("#redactor_tab_selected").val(2);c("#redactor_link_mailto").val(f.replace("mailto:",""));}else{if(m.search(/^#/gi)===0){this.modalSetTab.call(this,3);c("#redactor_tab_selected").val(3);c("#redactor_link_anchor").val(m.replace(/^#/gi,""));}else{c("#redactor_link_url").val(m);}}}if(i==="_blank"){c("#redactor_link_blank").prop("checked",true);}c("#redactor_insert_link_btn").click(c.proxy(this.linkProcess,this));setTimeout(function(){c("#redactor_link_url").focus();},200);},this);this.modalInit(this.opts.curLang.link,this.opts.modal_link,460,e);},linkProcess:function(){var i=c("#redactor_tab_selected").val();var g="",m="",j="",l="";if(i==="1"){g=c("#redactor_link_url").val();m=c("#redactor_link_url_text").val();if(c("#redactor_link_blank").prop("checked")){j=' target="_blank"';l="_blank";}var h="((xn--)?[a-z0-9]+(-[a-z0-9]+)*.)+[a-z]{2,}";var f=new RegExp("^(http|ftp|https)://"+h,"i");var e=new RegExp("^"+h,"i");if(g.search(f)==-1&&g.search(e)==0&&this.opts.linkProtocol){g=this.opts.linkProtocol+g;}}else{if(i==="2"){g="mailto:"+c("#redactor_link_mailto").val();m=c("#redactor_link_mailto_text").val();}else{if(i==="3"){g="#"+c("#redactor_link_anchor").val();m=c("#redactor_link_anchor_text").val();}}}m=m.replace(/<|>/g,"");this.linkInsert('<a href="'+g+'"'+j+">"+m+"</a>",c.trim(m),g,l);},linkInsert:function(e,h,f,g){this.selectionRestore();if(h!==""){if(this.insert_link_node){this.bufferSet();c(this.insert_link_node).text(h).attr("href",f);if(g!==""){c(this.insert_link_node).attr("target",g);}else{c(this.insert_link_node).removeAttr("target");}this.sync();}else{this.exec("inserthtml",e);}}setTimeout(c.proxy(function(){if(this.opts.observeLinks){this.observeLinks();}},this),5);this.modalClose();},fileShow:function(){this.selectionSave();var e=c.proxy(function(){var f=this.getSelection();var g="";if(this.oldIE()){g=f.text;}else{g=f.toString();}c("#redactor_filename").val(g);if(!this.isMobile()){this.draguploadInit("#redactor_file",{url:this.opts.fileUpload,uploadFields:this.opts.uploadFields,success:c.proxy(this.fileCallback,this),error:c.proxy(function(i,h){this.callback("fileUploadError",h);},this),uploadParam:this.opts.fileUploadParam});}this.uploadInit("redactor_file",{auto:true,url:this.opts.fileUpload,success:c.proxy(this.fileCallback,this),error:c.proxy(function(i,h){this.callback("fileUploadError",h);},this)});},this);this.modalInit(this.opts.curLang.file,this.opts.modal_file,500,e);},fileCallback:function(f){this.selectionRestore();if(f!==false){var h=c("#redactor_filename").val();if(h===""){h=f.filename;}var g='<a href="'+f.filelink+'" id="filelink-marker">'+h+"</a>";if(this.browser("webkit")&&!!this.window.chrome){g=g+"&nbsp;";}this.execCommand("inserthtml",g,false);var e=c(this.$editor.find("a#filelink-marker"));if(e.size()!=0){e.removeAttr("id");}else{e=false;}this.sync();this.callback("fileUpload",e,f);}this.modalClose();},imageShow:function(){this.selectionSave();var e=c.proxy(function(){if(this.opts.imageGetJson){c.getJSON(this.opts.imageGetJson,c.proxy(function(l){var h={},j=0;c.each(l,c.proxy(function(n,o){if(typeof o.folder!=="undefined"){j++;h[o.folder]=j;}},this));var i=false;c.each(l,c.proxy(function(q,r){var p="";if(typeof r.title!=="undefined"){p=r.title;}var n=0;if(!c.isEmptyObject(h)&&typeof r.folder!=="undefined"){n=h[r.folder];if(i===false){i=".redactorfolder"+n;}}var o=c('<img src="'+r.thumb+'" class="redactorfolder redactorfolder'+n+'" rel="'+r.image+'" title="'+p+'" />');c("#redactor_image_box").append(o);c(o).click(c.proxy(this.imageThumbClick,this));},this));if(!c.isEmptyObject(h)){c(".redactorfolder").hide();c(i).show();var m=function(n){c(".redactorfolder").hide();c(".redactorfolder"+c(n.target).val()).show();};var g=c('<select id="redactor_image_box_select">');c.each(h,function(o,n){g.append(c('<option value="'+n+'">'+o+"</option>"));});c("#redactor_image_box").before(g);g.change(m);}},this));}else{c("#redactor_tabs").find("a").eq(1).remove();}if(this.opts.imageUpload||this.opts.s3){if(!this.isMobile()&&this.opts.s3===false){if(c("#redactor_file").length){this.draguploadInit("#redactor_file",{url:this.opts.imageUpload,uploadFields:this.opts.uploadFields,success:c.proxy(this.imageCallback,this),error:c.proxy(function(h,g){this.callback("imageUploadError",g);},this),uploadParam:this.opts.imageUploadParam});}}if(this.opts.s3===false){this.uploadInit("redactor_file",{auto:true,url:this.opts.imageUpload,success:c.proxy(this.imageCallback,this),error:c.proxy(function(h,g){this.callback("imageUploadError",g);},this)});}else{c("#redactor_file").on("change.redactor",c.proxy(this.s3handleFileSelect,this));}}else{c(".redactor_tab").hide();if(!this.opts.imageGetJson){c("#redactor_tabs").remove();c("#redactor_tab3").show();}else{var f=c("#redactor_tabs").find("a");f.eq(0).remove();f.eq(1).addClass("redactor_tabs_act");c("#redactor_tab2").show();}}c("#redactor_upload_btn").click(c.proxy(this.imageCallbackLink,this));if(!this.opts.imageUpload&&!this.opts.imageGetJson){setTimeout(function(){c("#redactor_file_link").focus();},200);}},this);this.modalInit(this.opts.curLang.image,this.opts.modal_image,610,e);},imageEdit:function(g){var e=g;var f=e.parent().parent();var h=c.proxy(function(){c("#redactor_file_alt").val(e.attr("alt"));c("#redactor_image_edit_src").attr("href",e.attr("src"));c("#redactor_form_image_align").val(e.css("float"));if(c(f).get(0).tagName==="A"){c("#redactor_file_link").val(c(f).attr("href"));if(c(f).attr("target")=="_blank"){c("#redactor_link_blank").prop("checked",true);}}c("#redactor_image_delete_btn").click(c.proxy(function(){this.imageRemove(e);},this));c("#redactorSaveBtn").click(c.proxy(function(){this.imageSave(e);},this));},this);this.modalInit(this.opts.curLang.edit,this.opts.modal_image_edit,380,h);},imageRemove:function(f){var e=c(f).parent();c(f).remove();if(e.length&&e[0].tagName==="P"){this.$editor.focus();this.selectionStart(e);}this.callback("imageDelete",f);this.modalClose();this.sync();},imageSave:function(h){var f=c(h);var g=f.parent();f.attr("alt",c("#redactor_file_alt").val());var m=c("#redactor_form_image_align").val();if(m==="left"){f.css({"float":"left",margin:"0 "+this.opts.imageFloatMargin+" "+this.opts.imageFloatMargin+" 0"});}else{if(m==="right"){f.css({"float":"right",margin:"0 0 "+this.opts.imageFloatMargin+" "+this.opts.imageFloatMargin+""});}else{var j=f.closest("#redactor-image-box");if(j.size()!=0){j.css({"float":"",margin:""});}f.css({"float":"",margin:""});}}var i=c.trim(c("#redactor_file_link").val());if(i!==""){var l=false;if(c("#redactor_link_blank").prop("checked")){l=true;}if(g.get(0).tagName!=="A"){var e=c('<a href="'+i+'">'+this.outerHtml(h)+"</a>");if(l){e.attr("target","_blank");}f.replaceWith(e);}else{g.attr("href",i);if(l){g.attr("target","_blank");}else{g.removeAttr("target");}}}else{if(g.get(0).tagName==="A"){g.replaceWith(this.outerHtml(h));}}this.modalClose();this.observeImages();this.sync();},imageResizeHide:function(h){if(h!==false&&c(h.target).parent().size()!=0&&c(h.target).parent()[0].id==="redactor-image-box"){return false;}var f=this.$editor.find("#redactor-image-box");if(f.size()==0){return false;}this.$editor.find("#redactor-image-editter, #redactor-image-resizer").remove();var g=f[0].style.margin;if(g!="0px"){f.find("img").css("margin",g);f.css("margin","");}f.find("img").css("opacity","");f.replaceWith(function(){return c(this).contents();});c(document).off("click.redactor-image-resize-hide");this.$editor.off("click.redactor-image-resize-hide");this.$editor.off("keydown.redactor-image-delete");this.sync();},imageResize:function(f){var e=c(f);e.on("mousedown",c.proxy(function(){this.imageResizeHide(false);},this));e.on("dragstart",c.proxy(function(){this.$editor.on("drop.redactor-image-inside-drop",c.proxy(function(){setTimeout(c.proxy(function(){this.observeImages();this.$editor.off("drop.redactor-image-inside-drop");this.sync();},this),1);},this));},this));e.on("click",c.proxy(function(j){if(this.$editor.find("#redactor-image-box").size()!=0){return false;}var m=false,p,o,l=e.width()/e.height(),n=20,i=10;var g=this.imageResizeControls(e);var h=false;g.on("mousedown",function(q){h=true;q.preventDefault();l=e.width()/e.height();p=Math.round(q.pageX-e.eq(0).offset().left);o=Math.round(q.pageY-e.eq(0).offset().top);});c(this.document.body).on("mousemove",c.proxy(function(u){if(h){var r=Math.round(u.pageX-e.eq(0).offset().left)-p;var q=Math.round(u.pageY-e.eq(0).offset().top)-o;var t=e.height();var v=parseInt(t,10)+q;var s=Math.round(v*l);if(s>n){e.width(s);if(s<100){this.imageEditter.css({marginTop:"-7px",marginLeft:"-13px",fontSize:"9px",padding:"3px 5px"});}else{this.imageEditter.css({marginTop:"-11px",marginLeft:"-18px",fontSize:"11px",padding:"7px 10px"});}}p=Math.round(u.pageX-e.eq(0).offset().left);o=Math.round(u.pageY-e.eq(0).offset().top);this.sync();}},this)).on("mouseup",function(){h=false;});this.$editor.on("keydown.redactor-image-delete",c.proxy(function(r){var q=r.which;if(this.keyCode.BACKSPACE==q||this.keyCode.DELETE==q){this.imageResizeHide(false);this.imageRemove(e);}},this));c(document).on("click.redactor-image-resize-hide",c.proxy(this.imageResizeHide,this));this.$editor.on("click.redactor-image-resize-hide",c.proxy(this.imageResizeHide,this));},this));},imageResizeControls:function(f){var g=c('<span id="redactor-image-box" data-redactor="verified">');g.css({position:"relative",display:"inline-block",lineHeight:0,outline:"1px dashed rgba(0, 0, 0, .6)","float":f.css("float")});g.attr("contenteditable",false);var h=f[0].style.margin;if(h!="0px"){g.css("margin",h);f.css("margin","");}f.css("opacity",0.5).after(g);this.imageEditter=c('<span id="redactor-image-editter" data-redactor="verified">'+this.opts.curLang.edit+"</span>");this.imageEditter.css({position:"absolute",zIndex:2,top:"50%",left:"50%",marginTop:"-11px",marginLeft:"-18px",lineHeight:1,backgroundColor:"#000",color:"#fff",fontSize:"11px",padding:"7px 10px",cursor:"pointer"});this.imageEditter.attr("contenteditable",false);this.imageEditter.on("click",c.proxy(function(){this.imageEdit(f);},this));g.append(this.imageEditter);var e=c('<span id="redactor-image-resizer" data-redactor="verified"></span>');e.css({position:"absolute",zIndex:2,lineHeight:1,cursor:"nw-resize",bottom:"-4px",right:"-5px",border:"1px solid #fff",backgroundColor:"#000",width:"8px",height:"8px"});e.attr("contenteditable",false);g.append(e);g.append(f);return e;},imageThumbClick:function(g){var f='<img id="image-marker" src="'+c(g.target).attr("rel")+'" alt="'+c(g.target).attr("title")+'" />';if(this.opts.paragraphy){f="<p>"+f+"</p>";}this.imageInsert(f,true);},imageCallbackLink:function(){var f=c("#redactor_file_link").val();if(f!==""){var e='<img id="image-marker" src="'+f+'" />';if(this.opts.linebreaks===false){e="<p>"+e+"</p>";}this.imageInsert(e,true);}else{this.modalClose();}},imageCallback:function(e){this.imageInsert(e);},imageInsert:function(f,g){this.selectionRestore();if(f!==false){var e="";if(g!==true){e='<img id="image-marker" src="'+f.filelink+'" />';if(this.opts.paragraphy){e="<p>"+e+"</p>";}}else{e=f;}this.execCommand("inserthtml",e,false);var h=c(this.$editor.find("img#image-marker"));if(h.length){h.removeAttr("id");}else{h=false;}this.sync();g!==true&&this.callback("imageUpload",h,f);}this.modalClose();this.observeImages();},modalTemplatesInit:function(){c.extend(this.opts,{modal_file:String()+'<section><div id="redactor-progress" class="redactor-progress redactor-progress-striped" style="display: none;"><div id="redactor-progress-bar" class="redactor-progress-bar" style="width: 100%;"></div></div><form id="redactorUploadFileForm" method="post" action="" enctype="multipart/form-data"><label>'+this.opts.curLang.filename+'</label><input type="text" id="redactor_filename" class="redactor_input" /><div style="margin-top: 7px;"><input type="file" id="redactor_file" name="'+this.opts.fileUploadParam+'" /></div></form></section>',modal_image_edit:String()+"<section><label>"+this.opts.curLang.title+'</label><input id="redactor_file_alt" class="redactor_input" /><label>'+this.opts.curLang.link+'</label><input id="redactor_file_link" class="redactor_input" /><label><input type="checkbox" id="redactor_link_blank"> '+this.opts.curLang.link_new_tab+"</label><label>"+this.opts.curLang.image_position+'</label><select id="redactor_form_image_align"><option value="none">'+this.opts.curLang.none+'</option><option value="left">'+this.opts.curLang.left+'</option><option value="right">'+this.opts.curLang.right+'</option></select></section><footer><button id="redactor_image_delete_btn" class="redactor_modal_btn redactor_modal_delete_btn">'+this.opts.curLang._delete+'</button>&nbsp;&nbsp;&nbsp;<button class="redactor_modal_btn redactor_btn_modal_close">'+this.opts.curLang.cancel+'</button><input type="button" name="save" class="redactor_modal_btn redactor_modal_action_btn" id="redactorSaveBtn" value="'+this.opts.curLang.save+'" /></footer>',modal_image:String()+'<section><div id="redactor_tabs"><a href="#" class="redactor_tabs_act">'+this.opts.curLang.upload+'</a><a href="#">'+this.opts.curLang.choose+'</a><a href="#">'+this.opts.curLang.link+'</a></div><div id="redactor-progress" class="redactor-progress redactor-progress-striped" style="display: none;"><div id="redactor-progress-bar" class="redactor-progress-bar" style="width: 100%;"></div></div><form id="redactorInsertImageForm" method="post" action="" enctype="multipart/form-data"><div id="redactor_tab1" class="redactor_tab"><input type="file" id="redactor_file" name="'+this.opts.imageUploadParam+'" /></div><div id="redactor_tab2" class="redactor_tab" style="display: none;"><div id="redactor_image_box"></div></div></form><div id="redactor_tab3" class="redactor_tab" style="display: none;"><label>'+this.opts.curLang.image_web_link+'</label><input type="text" name="redactor_file_link" id="redactor_file_link" class="redactor_input"  /></div></section><footer><button class="redactor_modal_btn redactor_btn_modal_close">'+this.opts.curLang.cancel+'</button><input type="button" name="upload" class="redactor_modal_btn redactor_modal_action_btn" id="redactor_upload_btn" value="'+this.opts.curLang.insert+'" /></footer>',modal_link:String()+'<section><form id="redactorInsertLinkForm" method="post" action=""><div id="redactor_tabs"><a href="#" class="redactor_tabs_act">URL</a><a href="#">Email</a><a href="#">'+this.opts.curLang.anchor+'</a></div><input type="hidden" id="redactor_tab_selected" value="1" /><div class="redactor_tab" id="redactor_tab1"><label>URL</label><input type="text" id="redactor_link_url" class="redactor_input"  /><label>'+this.opts.curLang.text+'</label><input type="text" class="redactor_input redactor_link_text" id="redactor_link_url_text" /><label><input type="checkbox" id="redactor_link_blank"> '+this.opts.curLang.link_new_tab+'</label></div><div class="redactor_tab" id="redactor_tab2" style="display: none;"><label>Email</label><input type="text" id="redactor_link_mailto" class="redactor_input" /><label>'+this.opts.curLang.text+'</label><input type="text" class="redactor_input redactor_link_text" id="redactor_link_mailto_text" /></div><div class="redactor_tab" id="redactor_tab3" style="display: none;"><label>'+this.opts.curLang.anchor+'</label><input type="text" class="redactor_input" id="redactor_link_anchor"  /><label>'+this.opts.curLang.text+'</label><input type="text" class="redactor_input redactor_link_text" id="redactor_link_anchor_text" /></div></form></section><footer><button class="redactor_modal_btn redactor_btn_modal_close">'+this.opts.curLang.cancel+'</button><input type="button" class="redactor_modal_btn redactor_modal_action_btn" id="redactor_insert_link_btn" value="'+this.opts.curLang.insert+'" /></footer>',modal_table:String()+"<section><label>"+this.opts.curLang.rows+'</label><input type="text" size="5" value="2" id="redactor_table_rows" /><label>'+this.opts.curLang.columns+'</label><input type="text" size="5" value="3" id="redactor_table_columns" /></section><footer><button class="redactor_modal_btn redactor_btn_modal_close">'+this.opts.curLang.cancel+'</button><input type="button" name="upload" class="redactor_modal_btn redactor_modal_action_btn" id="redactor_insert_table_btn" value="'+this.opts.curLang.insert+'" /></footer>',modal_video:String()+'<section><form id="redactorInsertVideoForm"><label>'+this.opts.curLang.video_html_code+'</label><textarea id="redactor_insert_video_area" style="width: 99%; height: 160px;"></textarea></form></section><footer><button class="redactor_modal_btn redactor_btn_modal_close">'+this.opts.curLang.cancel+'</button><input type="button" class="redactor_modal_btn redactor_modal_action_btn" id="redactor_insert_video_btn" value="'+this.opts.curLang.insert+'" /></footer>'});},modalInit:function(l,h,f,m){var e=c("#redactor_modal_overlay");if(!e.length){this.$overlay=e=c('<div id="redactor_modal_overlay" style="display: none;"></div>');c("body").prepend(this.$overlay);}if(this.opts.modalOverlay){e.show().on("click",c.proxy(this.modalClose,this));}var i=c("#redactor_modal");if(!i.length){this.$modal=i=c('<div id="redactor_modal" style="display: none;"><div id="redactor_modal_close">&times;</div><header id="redactor_modal_header"></header><div id="redactor_modal_inner"></div></div>');c("body").append(this.$modal);}c("#redactor_modal_close").on("click",c.proxy(this.modalClose,this));this.hdlModalClose=c.proxy(function(n){if(n.keyCode===this.keyCode.ESC){this.modalClose();return false;}},this);c(document).keyup(this.hdlModalClose);this.$editor.keyup(this.hdlModalClose);this.modalcontent=false;if(h.indexOf("#")==0){this.modalcontent=c(h);c("#redactor_modal_inner").empty().append(this.modalcontent.html());this.modalcontent.html("");}else{c("#redactor_modal_inner").empty().append(h);}i.find("#redactor_modal_header").html(l);if(typeof c.fn.draggable!=="undefined"){i.draggable({handle:"#redactor_modal_header"});i.find("#redactor_modal_header").css("cursor","move");}var j=c("#redactor_tabs");if(j.length){var g=this;j.find("a").each(function(n,o){n++;c(o).on("click",function(q){q.preventDefault();j.find("a").removeClass("redactor_tabs_act");c(this).addClass("redactor_tabs_act");c(".redactor_tab").hide();c("#redactor_tab"+n).show();c("#redactor_tab_selected").val(n);if(g.isMobile()===false){var p=i.outerHeight();i.css("margin-top","-"+(p+10)/2+"px");}});});}i.find(".redactor_btn_modal_close").on("click",c.proxy(this.modalClose,this));if(this.opts.autoresize===true){this.saveModalScroll=this.document.body.scrollTop;}if(this.isMobile()===false){i.css({position:"fixed",top:"-2000px",left:"50%",width:f+"px",marginLeft:"-"+(f+60)/2+"px"}).show();this.modalSaveBodyOveflow=c(document.body).css("overflow");c(document.body).css("overflow","hidden");}else{i.css({position:"fixed",width:"100%",height:"100%",top:"0",left:"0",margin:"0",minHeight:"300px"}).show();}if(typeof m==="function"){m();}if(this.isMobile()===false){setTimeout(function(){var n=i.outerHeight();i.css({top:"50%",height:"auto",minHeight:"auto",marginTop:"-"+(n+10)/2+"px"});},10);}},modalClose:function(){c("#redactor_modal_close").off("click",this.modalClose);c("#redactor_modal").fadeOut("fast",c.proxy(function(){var e=c("#redactor_modal_inner");if(this.modalcontent!==false){this.modalcontent.html(e.html());this.modalcontent=false;}e.html("");if(this.opts.modalOverlay){c("#redactor_modal_overlay").hide().off("click",this.modalClose);}c(document).unbind("keyup",this.hdlModalClose);this.$editor.unbind("keyup",this.hdlModalClose);this.selectionRestore();if(this.opts.autoresize&&this.saveModalScroll){c(this.document.body).scrollTop(this.saveModalScroll);}},this));if(this.isMobile()===false){c(document.body).css("overflow",this.modalSaveBodyOveflow?this.modalSaveBodyOveflow:"visible");}return false;},modalSetTab:function(e){c(".redactor_tab").hide();c("#redactor_tabs").find("a").removeClass("redactor_tabs_act").eq(e-1).addClass("redactor_tabs_act");c("#redactor_tab"+e).show();},s3handleFileSelect:function(l){var h=l.target.files;for(var g=0,j;j=h[g];g++){this.s3uploadFile(j);}},s3uploadFile:function(e){this.s3executeOnSignedUrl(e,c.proxy(function(f){this.s3uploadToS3(e,f);},this));},s3executeOnSignedUrl:function(e,g){var f=new XMLHttpRequest();f.open("GET",this.opts.s3+"?name="+e.name+"&type="+e.type,true);f.overrideMimeType("text/plain; charset=x-user-defined");f.onreadystatechange=function(h){if(this.readyState==4&&this.status==200){c("#redactor-progress").fadeIn();g(decodeURIComponent(this.responseText));}else{if(this.readyState==4&&this.status!=200){}}};f.send();},s3createCORSRequest:function(g,e){var f=new XMLHttpRequest();if("withCredentials" in f){f.open(g,e,true);}else{if(typeof XDomainRequest!="undefined"){f=new XDomainRequest();f.open(g,e);}else{f=null;}}return f;},s3uploadToS3:function(f,e){var g=this.s3createCORSRequest("PUT",e);if(!g){}else{g.onload=c.proxy(function(){if(g.status==200){c("#redactor-progress").hide();var j=e.split("?");if(!j[0]){return false;}this.selectionRestore();var h="";h='<img id="image-marker" src="'+j[0]+'" />';if(this.opts.paragraphy){h="<p>"+h+"</p>";}this.execCommand("inserthtml",h,false);var i=c(this.$editor.find("img#image-marker"));if(i.length){i.removeAttr("id");}else{i=false;}this.sync();this.callback("imageUpload",i,false);this.modalClose();this.observeImages();}else{}},this);g.onerror=function(){};g.upload.onprogress=function(h){};g.setRequestHeader("Content-Type",f.type);g.setRequestHeader("x-amz-acl","public-read");g.send(f);}},uploadInit:function(g,e){this.uploadOptions={url:false,success:false,error:false,start:false,trigger:false,auto:false,input:false};c.extend(this.uploadOptions,e);var f=c("#"+g);if(f.length&&f[0].tagName==="INPUT"){this.uploadOptions.input=f;this.el=c(f[0].form);}else{this.el=f;}this.element_action=this.el.attr("action");if(this.uploadOptions.auto){c(this.uploadOptions.input).change(c.proxy(function(h){this.el.submit(function(i){return false;});this.uploadSubmit(h);},this));}else{if(this.uploadOptions.trigger){c("#"+this.uploadOptions.trigger).click(c.proxy(this.uploadSubmit,this));}}},uploadSubmit:function(f){c("#redactor-progress").fadeIn();this.uploadForm(this.element,this.uploadFrame());},uploadFrame:function(){this.id="f"+Math.floor(Math.random()*99999);var f=this.document.createElement("div");var e='<iframe style="display:none" id="'+this.id+'" name="'+this.id+'"></iframe>';f.innerHTML=e;c(f).appendTo("body");if(this.uploadOptions.start){this.uploadOptions.start();}c("#"+this.id).load(c.proxy(this.uploadLoaded,this));return this.id;},uploadForm:function(i,h){if(this.uploadOptions.input){var j="redactorUploadForm"+this.id,e="redactorUploadFile"+this.id;this.form=c('<form  action="'+this.uploadOptions.url+'" method="POST" target="'+h+'" name="'+j+'" id="'+j+'" enctype="multipart/form-data" />');if(this.opts.uploadFields!==false&&typeof this.opts.uploadFields==="object"){c.each(this.opts.uploadFields,c.proxy(function(m,f){if(f!=null&&f.toString().indexOf("#")===0){f=c(f).val();}var n=c("<input/>",{type:"hidden",name:m,value:f});c(this.form).append(n);},this));}var g=this.uploadOptions.input;var l=c(g).clone();c(g).attr("id",e).before(l).appendTo(this.form);c(this.form).css("position","absolute").css("top","-2000px").css("left","-2000px").appendTo("body");this.form.submit();}else{i.attr("target",h).attr("method","POST").attr("enctype","multipart/form-data").attr("action",this.uploadOptions.url);this.element.submit();}},uploadLoaded:function(){var h=c("#"+this.id)[0],j;if(h.contentDocument){j=h.contentDocument;}else{if(h.contentWindow){j=h.contentWindow.document;}else{j=window.frames[this.id].document;}}if(this.uploadOptions.success){c("#redactor-progress").hide();if(typeof j!=="undefined"){var g=j.body.innerHTML;var f=g.match(/\{(.|\n)*\}/)[0];f=f.replace(/^\[/,"");f=f.replace(/\]$/,"");var e=c.parseJSON(f);if(typeof e.error=="undefined"){this.uploadOptions.success(e);}else{this.uploadOptions.error(this,e);this.modalClose();}}else{this.modalClose();alert("Upload failed!");}}this.el.attr("action",this.element_action);this.el.attr("target","");},draguploadInit:function(f,e){this.draguploadOptions=c.extend({url:false,success:false,error:false,preview:false,uploadFields:false,text:this.opts.curLang.drop_file_here,atext:this.opts.curLang.or_choose,uploadParam:false},e);if(window.FormData===undefined){return false;}this.droparea=c('<div class="redactor_droparea"></div>');this.dropareabox=c('<div class="redactor_dropareabox">'+this.draguploadOptions.text+"</div>");this.dropalternative=c('<div class="redactor_dropalternative">'+this.draguploadOptions.atext+"</div>");this.droparea.append(this.dropareabox);c(f).before(this.droparea);c(f).before(this.dropalternative);this.dropareabox.on("dragover",c.proxy(function(){return this.draguploadOndrag();},this));this.dropareabox.on("dragleave",c.proxy(function(){return this.draguploadOndragleave();},this));this.dropareabox.get(0).ondrop=c.proxy(function(g){g.preventDefault();this.dropareabox.removeClass("hover").addClass("drop");this.dragUploadAjax(this.draguploadOptions.url,g.dataTransfer.files[0],false,false,false,this.draguploadOptions.uploadParam);},this);},dragUploadAjax:function(h,j,f,g,m,l){if(!f){var n=c.ajaxSettings.xhr();if(n.upload){n.upload.addEventListener("progress",c.proxy(this.uploadProgress,this),false);}c.ajaxSetup({xhr:function(){return n;}});}var i=new FormData();if(l!==false){i.append(l,j);}else{i.append("file",j);}if(this.opts.uploadFields!==false&&typeof this.opts.uploadFields==="object"){c.each(this.opts.uploadFields,c.proxy(function(o,e){if(e!=null&&e.toString().indexOf("#")===0){e=c(e).val();}i.append(o,e);},this));}c.ajax({url:h,dataType:"html",data:i,cache:false,contentType:false,processData:false,type:"POST",success:c.proxy(function(p){p=p.replace(/^\[/,"");p=p.replace(/\]$/,"");var o=(typeof p==="string"?c.parseJSON(p):p);if(f){g.fadeOut("slow",function(){c(this).remove();});var e=c("<img>");e.attr("src",o.filelink).attr("id","drag-image-marker");this.insertNodeToCaretPositionFromPoint(m,e[0]);var q=c(this.$editor.find("img#drag-image-marker"));if(q.length){q.removeAttr("id");}else{q=false;}this.sync();this.observeImages();if(q){this.callback("imageUpload",q,o);}if(typeof o.error!=="undefined"){this.callback("imageUploadError",o);}}else{if(typeof o.error=="undefined"){this.draguploadOptions.success(o);}else{this.draguploadOptions.error(this,o);this.draguploadOptions.success(false);}}},this)});},draguploadOndrag:function(){this.dropareabox.addClass("hover");return false;},draguploadOndragleave:function(){this.dropareabox.removeClass("hover");return false;},uploadProgress:function(g,h){var f=g.loaded?parseInt(g.loaded/g.total*100,10):g;this.dropareabox.text("Loading "+f+"% "+(h||""));},isMobile:function(){return/(iPhone|iPod|BlackBerry|Android)/.test(navigator.userAgent);},normalize:function(e){if(typeof(e)==="undefined"){return 0;}return parseInt(e.replace("px",""),10);},outerHtml:function(e){return c("<div>").append(c(e).eq(0).clone()).html();},isString:function(e){return Object.prototype.toString.call(e)=="[object String]";},isEmpty:function(e){e=e.replace(/&#x200b;|<br>|<br\/>|&nbsp;/gi,"");e=e.replace(/\s/g,"");e=e.replace(/^<p>[^\W\w\D\d]*?<\/p>$/i,"");return e=="";},browser:function(f){var g=navigator.userAgent.toLowerCase();var e=/(chrome)[ \/]([\w.]+)/.exec(g)||/(webkit)[ \/]([\w.]+)/.exec(g)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(g)||/(msie) ([\w.]+)/.exec(g)||g.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(g)||[];if(f=="version"){return e[2];}if(f=="webkit"){return(e[1]=="chrome"||e[1]=="webkit");}return e[1]==f;},oldIE:function(){if(this.browser("msie")&&parseInt(this.browser("version"),10)<9){return true;}return false;},getFragmentHtml:function(f){var e=f.cloneNode(true);var g=this.document.createElement("div");g.appendChild(e);return g.innerHTML;},extractContent:function(){var e=this.$editor[0];var g=this.document.createDocumentFragment();var f;while((f=e.firstChild)){g.appendChild(f);}return g;},isParentRedactor:function(e){if(!e){return false;}if(this.opts.iframe){return e;}if(c(e).parents("div.redactor_editor").length==0||c(e).hasClass("redactor_editor")){return false;}else{return e;}},currentOrParentIs:function(e){var f=this.getParent(),g=this.getCurrent();return f&&f.tagName===e?f:g&&g.tagName===e?g:false;},isEndOfElement:function(){var f=this.getBlock();var h=this.getCaretOffset(f);var g=c.trim(c(f).text()).replace(/\n\r\n/g,"");var e=g.length;if(h==e){return true;}else{return false;}},isFocused:function(){var e,f=this.getSelection();if(f&&f.rangeCount&&f.rangeCount>0){e=f.getRangeAt(0).startContainer;}if(!e){return false;}if(this.opts.iframe){if(this.getCaretOffsetRange().equals()){return !this.$editor.is(e);}else{return true;}}return c(e).closest("div.redactor_editor").length!=0;},removeEmptyAttr:function(f,e){if(c(f).attr(e)==""){c(f).removeAttr(e);}},removeFromArrayByValue:function(g,f){var e=null;while((e=g.indexOf(f))!==-1){g.splice(e,1);}return g;}};b.prototype.init.prototype=b.prototype;c.Redactor.fn.formatLinkify=function(x,u,m,r,j){var s=/(^|&lt;|\s)(www\..+?\..+?)(\s|&gt;|$)/g,q=/(^|&lt;|\s)(((https?|ftp):\/\/|mailto:).+?)(\s|&gt;|$)/g,e=/(https?:\/\/.*\.(?:png|jpg|jpeg|gif))/gi,w=/^.*(youtu.be\/|u\/\w\/|embed\/|watch\?v=|\&v=)([^#\&\?]*).*/,t=/https?:\/\/(www\.)?vimeo.com\/(\d+)($|\/)/;var v=(this.$editor?this.$editor.get(0):this).childNodes,l=v.length;while(l--){var h=v[l];if(h.nodeType===3){var p=h.nodeValue;if(r&&p){var o='<iframe width="500" height="281" src="',g='" frameborder="0" allowfullscreen></iframe>';if(p.match(w)){p=p.replace(w,o+"//www.youtube.com/embed/$2"+g);c(h).after(p).remove();}else{if(p.match(t)){p=p.replace(t,o+"//player.vimeo.com/video/$2"+g);c(h).after(p).remove();}}}if(m&&p&&p.match(e)){p=p.replace(e,'<img src="$1">');c(h).after(p).remove();}if(u&&p&&(p.match(s)||p.match(q))){var f=(p.match(s)||p.match(q));f=f[0];if(f.length>j){f=f.substring(0,j)+"...";}p=p.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(s,'$1<a href="'+x+'$2">'+f+"</a>$3").replace(q,'$1<a href="$2">'+f+"</a>$5");c(h).after(p).remove();}}else{if(h.nodeType===1&&!/^(a|button|textarea)$/i.test(h.tagName)){c.Redactor.fn.formatLinkify.call(h,x,u,m,r,j);}}}};})(jQuery);
\ No newline at end of file