/*
*######################################
* eWebEditor V8.5 - Advanced online web based WYSIWYG HTML editor.
* Copyright (c) 2003-2012 eWebSoft.com
*
* For further information go to http://www.ewebeditor.net/
* This copyright notice MUST stay intact for use.
*######################################
*/

String.prototype.fw=function(s){return(this.indexOf(s)> -1);};String.prototype.Av=function(s){return(this.substr(0,s.length)==s);};String.prototype.eg=function(s,ignoreCase){var L1=this.length;var L2=s.length;if(L2>L1){return false;}if(ignoreCase){var sV=new RegExp(s+'$','i');return sV.test(this);}else{return(L2==0||this.substr(L1-L2,L2)==s);}};String.prototype.oz=function(){return this.replace(/(^[ \t\n\r]*)|([ \t\n\r]*$)/g,'');};Array.prototype.IndexOf=function(s){for(var i=0;i<this.length;i++){if(this[i]==s){return i;}}return-1;};(function(){var rJ=/()??/.exec("")[1]===undefined;var ph=function(){var x=/^/g;x.test("");return!x.lastIndex;}();var eS={exec:RegExp.prototype.exec,match:String.prototype.match,replace:String.prototype.replace,split:String.prototype.split,test:RegExp.prototype.test};var uF=function(array,item,from){for(var i=from||0;i<array.length;i++){if(array[i]===item){return i;}}return-1;};var tF=function(cC){return(cC.global?"g":"")+(cC.ignoreCase?"i":"")+(cC.multiline?"m":"")+(cC.extended?"x":"")+(cC.sticky?"y":"");};var mZ=function(o){return Object.prototype.toString.call(o)==="[object RegExp]";};RegExp.prototype.exec=function(bM){var match=eS.exec.apply(this,arguments),name,r2;if(match){if(!rJ&&match.length>1&&uF(match,"")> -1){r2=RegExp("^"+this.source+"$(?!\\s)",tF(this));eS.replace.call(match[0],r2,function(){for(var i=1;i<arguments.length-2;i++){if(arguments[i]===undefined){match[i]=undefined;}}});}if(!ph&&this.global&&this.lastIndex>(match.index+match[0].length)){this.lastIndex--;}}return match;};if(!ph){RegExp.prototype.test=function(bM){var match=eS.exec.call(this,bM);if(match&&this.global&&this.lastIndex>(match.index+match[0].length)){this.lastIndex--;}return! !match;};}String.prototype.match=function(cC){if(!mZ(cC)){cC=RegExp(cC);}if(cC.global){var result=eS.match.apply(this,arguments);cC.lastIndex=0;return result;}return cC.exec(this);};String.prototype.split=function(s,dq){if(!mZ(s)){return eS.split.apply(this,arguments);}var bM=this+"",output=[],hz=0,match,mp;if(dq===undefined|| +dq<0){dq=Infinity;}else{dq=Math.floor(+dq);if(!dq){return[];}}while(match=s.exec(bM)){if(s.lastIndex>hz){output.push(bM.slice(hz,match.index));if(match.length>1&&match.index<bM.length){Array.prototype.push.apply(output,match.slice(1));}mp=match[0].length;hz=s.lastIndex;if(output.length>=dq){break;}}if(!match[0].length){s.lastIndex++;}}if(hz===bM.length){if(!eS.test.call(s,"")||mp){output.push("");}}else{output.push(bM.slice(hz));}return output.length>dq?output.slice(0,dq):output;};})();var aA=(function(){var iW=new Object();var qR=document.location.search.substr(1).split("&");for(i=0;i<qR.length;i++){var qD=qR[i].split("=");iW[qD[0]]=qD[1];}var al=function(bA,sz){return(iW[bA])?iW[bA]:sz;};var om=al("id","");var pA=al("originalfilename","");var qT=al("savefilename","");var rc=al("savepathfilename","");var sx=al("extcss","");var rY=al("fullscreen","");var rr=al("style","coolblue");var ki=al("cusdir","");var rH=al("skin","");var rM=al("fixwidth","");var ca=al("lang","");var tk=al("areacssmode","");var sc=al("readonly","");var tf=al("skey","");var sM=al("instanceid",om);var rA=al("autogrow","");var hw=document.location.host;var n=hw.indexOf(":");if(n>0){hw=hw.substring(0,n);}return{bs:om,vs:sM,wg:pA,vZ:qT,vj:rc,ExtCSS:sx,FullScreen:rY,StyleName:rr,CusDir:ki,Skin:rH,FixWidth:rM,Lang:ca,AreaCssMode:tk,ReadOnly:sc,SKey:tf,rD:rA,H:hw};})();var F=(function(){var s=navigator.userAgent.toLowerCase();var os=( /*@cc_on!@*/false);var hs=0;if(os){hs=parseInt(s.match(/msie (\d+)/)[1],10);}return{as:os,xZ:(hs==6),zW:(hs>=6),gB:(hs>=7),zP:(hs>=8),BI:(hs>=10),Cf:(os&&(s.indexOf("trident/5")> -1)),An: ! !document.documentMode,Ar:document.documentMode==8,nb:document.documentMode==9,jo:s.fw('gecko/'),ik:s.fw('safari'),jr: ! !window.opera,Bx:s.fw(' adobeair/'),Aq:s.fw('macintosh'),AM:s.fw('chrome/'),xb:s.fw(' applewebkit/'),iF:true};})();var lang=new Object();lang.ji={"da":true,"de":true,"en":true,"fr":true,"it":true,"es":true,"ja":true,"nl":true,"no":true,"pt":true,"ru":true,"sv":true,"zh-cn":true,"zh-tw":true};lang.vc=function(){if(aA.Lang){return aA.Lang;}if(config.AutoDetectLanguage=="1"){var cG;if(navigator.userLanguage){cG=navigator.userLanguage.toLowerCase();}else if(navigator.language){cG=navigator.language.toLowerCase();}else{return this.DefaultLanguage;}if(this.ji[cG]){return cG;}else if(cG.length>2){cG=cG.substr(0,2);if(this.ji[cG]){return cG;}}}return this.DefaultLanguage;};lang.ag=function(fT){var gT=fT.getElementsByTagName("INPUT");for(i=0;i<gT.length;i++){if(gT[i].getAttribute("lang")){gT[i].value=lang[gT[i].getAttribute("lang")];}}var gZ=fT.getElementsByTagName("SPAN");for(i=0;i<gZ.length;i++){if(gZ[i].getAttribute("lang")){gZ[i].innerHTML=lang[gZ[i].getAttribute("lang")];}}var ht=fT.getElementsByTagName("OPTION");for(i=0;i<ht.length;i++){if(ht[i].getAttribute("lang")){ht[i].innerHTML=lang[ht[i].getAttribute("lang")];}}};lang.Init=function(){if(this.ji[config.DefaultLanguage]){this.DefaultLanguage=config.DefaultLanguage;}else{this.DefaultLanguage="en";}this.bF=this.vc();};var am=(function(){var ut=9999;var ac,cv,aP;var kP,bf,kp,kg;var bH={x:0,y:0,ew:0,rel:null};var un;var eA;var gg=false;var cN;var mv=function(){if(ac){return;}kp="<table border=0 cellpadding=0 cellspacing=0 class='Menu_Box' id=Menu_Box><tr><td class='Menu_Box'><table border=0 cellpadding=0 cellspacing=0 class='Menu_Table'>";bf="<tr><td class='Menu_Sep'><table border=0 cellpadding=0 cellspacing=0 class='Menu_Sep'><tr><td></td></tr></table></td></tr>";kg="</table></td></tr></table>";kP="<html><head>"+"<link href='"+EWEB.cd+"/language/"+lang.bF+".css' type='text/css' rel='stylesheet'>"+"<link href='"+EWEB.cd+"/skin/"+config.Skin+"/menuarea.css' type='text/css' rel='stylesheet'>"+"</head>"+"<body scroll='no'>";if(F.as){cv=window.createPopup();ac=cv.document;ac.open();ac.write(kP);ac.close();}else{cN=R.lJ();var mK=cN.document;aP=mK.createElement('iframe');R.hh(aP);aP.src='javascript:void(0)';aP.allowTransparency=true;aP.frameBorder='0';aP.scrolling='no';aP.style.width=aP.style.height='0px';R.cP(aP,{position:'absolute',zIndex:ut});aP.kw=window;mK.body.appendChild(aP);var ln=aP.contentWindow;ac=ln.document;ac.open();ac.write(kP);ac.close();un=R.fR(ac);R.ko(ac.body);R.az(ln,'focus',sF);R.az(ln,'blur',rK);}eA=ac.body.appendChild(ac.createElement('DIV'));eA.style.cssFloat='left';R.az(ac,'contextmenu',R.aw);R.az(ac,'dragstart',R.aw);R.az(ac,'selectstart',R.aw);R.az(ac,'select',R.aw);};var dY=function(aW,pP,jn,V){var dX="";var js;if(F.as){js="var w=parent;w."+pP+";w.am.Hide();";}else{js="var w=frameElement.kw;w."+pP+";w.am.Hide();"}if(aW==""){dX+="<tr><td class='Menu_Item'><table border=0 cellpadding=0 cellspacing=0 width='100%'><tr><td valign=middle class=MouseOut onMouseOver=\"this.className='MouseOver'\" onMouseOut=\"this.className='MouseOut'\" onclick=\""+js+"\">";}else{dX+="<tr><td class='Menu_Item'><table border=0 cellpadding=0 cellspacing=0 width='100%'><tr><td valign=middle class=MouseDisabled>";}aW=(aW)?"_Disabled":"";dX+="<table border=0 cellpadding=0 cellspacing=0><tr><td class=Menu_Image_TD>";if(typeof(jn)=="number"){var cA="skin/"+config.Skin+"/buttons.gif";var dM=16-jn*16;dX+="<div class='Menu_Image"+aW+"'><img src='"+cA+"' style='top:"+dM+"px'></div>";}else if(jn!=""){var cA="skin/"+config.Skin+"/"+jn;dX+="<img class='Menu_Image"+aW+"' src='"+cA+"'>";}dX+="</td><td class='Menu_Label"+aW+"'>"+V+"</td></tr></table>";dX+="</td></tr></table></td><\/tr>";return dX;};var O=function(aW,aM,ca){var di=Buttons[aM];if(!ca){ca=lang[aM];}else{ca=lang[ca];}var hL=di[1]?di[1]:"exec('"+aM+"')";return dY(aW,hL,di[0],ca);};var bb=function(aM,aV){var aW="";if(!aV){aV=aM;}try{if(!EWEB.T.queryCommandEnabled(aV)){aW="disabled";}}catch(e){}return O(aW,aM);};var eN=function(what){var G="";var aW="disabled";switch(what){case "TableInsert":if(!bI.gl()){aW="";}G+=O(aW,"TableInsert");break;case "TableProp":if(bI.gl()||bI.bp()){aW="";}G+=O(aW,"TableProp");break;case "TableCell":if(bI.bp()){aW="";}G+=O(aW,"TableCellProp");G+=O(aW,"TableCellSplit");G+=bf;G+=O(aW,"TableRowProp");G+=O(aW,"TableRowInsertAbove");G+=O(aW,"TableRowInsertBelow");G+=O(aW,"TableRowMerge");G+=O(aW,"TableRowSplit");G+=O(aW,"TableRowDelete");G+=bf;G+=O(aW,"TableColInsertLeft");G+=O(aW,"TableColInsertRight");G+=O(aW,"TableColMerge");G+=O(aW,"TableColSplit");G+=O(aW,"TableColDelete");break;}return G;};var mV=function(aH,dg,iG){if(C.ai()=="Control"){if(aH){var el=C.ax();if(el.tagName.toUpperCase()==aH){if((dg)&&(iG)){if(el.getAttribute(dg,2).toLowerCase()==iG.toLowerCase()){return true;}}else{return true;}}}else{return true;}}return false;};tA=function(){if(ac.readyState!="complete"){return false;}if(ac.images){for(var i=0;i<ac.images.length;i++){var img=ac.images[i];if(!img.complete){return false;}}}return true;};return{Show:function(){if(F.as){if(!tA()){window.setTimeout("am.Show()",50);return;}var w=ac.body.scrollWidth;var h=ac.body.scrollHeight;if(bH.x+w>document.body.clientWidth){bH.x=bH.x-w+bH.ew;}cv.show(bH.x,bH.y,w,h,bH.rel);}else{var w=eA.offsetWidth;var h=eA.offsetHeight;var x=bH.x;var y=bH.y;if(ac.readyState!="complete"){window.setTimeout("am.Show()",50);return;}R.cP(aP,{width:w+'px',height:h+'px',left:x+'px',top:y+'px'});gg=true;}},fJ:function(e,an){if(EWEB.ae!="EDIT"){return R.aw(e);}mv();if(gg){this.Hide();}var G="";switch(an){case "font":G+=bb("Bold");G+=bb("Italic");G+=bb("UnderLine");G+=bb("StrikeThrough");G+=bf;G+=bb("SuperScript");G+=bb("SubScript");G+=bf;G+=O("","UpperCase");G+=O("","LowerCase");G+=bf;G+=O("","ForeColor");G+=O("","BackColor");G+=bf;G+=O("","Big");G+=O("","Small");break;case "paragraph":G+=bb("JustifyLeft");G+=bb("JustifyCenter");G+=bb("JustifyRight");G+=bb("JustifyFull");G+=bf;G+=bb("OrderedList","insertorderedlist");G+=bb("UnOrderedList","insertunorderedlist");G+=bb("Indent");G+=bb("Outdent");G+=bf;G+=bb("Paragraph","insertparagraph");G+=O("","BR");G+=bf;G+=O((iY())?"":"disabled","ParagraphAttr","CMenuParagraph");break;case "edit":var aW="";if(!ap.rs()){aW="disabled";}G+=O(aW,"UnDo");if(!ap.rC()){aW="disabled";}G+=O(aW,"ReDo");G+=bf;G+=bb("Cut");G+=bb("Copy");G+=O("","Paste");G+=O("","PasteText");G+=O("","PasteWord");G+=bf;G+=bb("Delete");G+=bb("RemoveFormat");G+=bf;G+=bb("SelectAll");G+=bb("UnSelect");G+=bf;G+=O("","FindReplace");G+=O("","QuickFormat");break;case "object":G+=O("","BgColor");G+=O("","BackImage");G+=bf;G+=O("","absolutePosition");G+=O("","zIndexForward");G+=O("","zIndexBackward");G+=bf;G+=O("","ShowBorders");G+=bf;G+=O("","Quote");G+=O("","Code");break;case "component":G+=O("","Image");G+=O("","Flash");G+=O("","Media");G+=O("","File");G+=bf;G+=O("","RemoteUpload");G+=O("","LocalUpload");G+=bf;G+=O("","Fieldset");G+=O("","Iframe");G+=bb("HorizontalRule","InsertHorizontalRule");G+=O("","Marquee");G+=bf;G+=O("","CreateLink");G+=O("","Anchor");G+=O("","Map");G+=bb("Unlink");break;case "tool":G+=O("","Template");G+=O("","Symbol");G+=O("","Excel");G+=O("","Emot");G+=bf;G+=O("","EQ");G+=O("","Art");G+=bf;G+=O("","NowDate");G+=O("","NowTime");G+=bf;G+=O("","ImportWord");G+=O("","ImportExcel");G+=O("","Capture");G+=bf;G+=O("","Pagination");G+=O("","PaginationInsert");break;case "file":G+=O("","Refresh");G+=bf;G+=O("","ModeCode");G+=O("","ModeEdit");G+=O("","ModeText");G+=O("","ModeView");G+=bf;G+=O("","SizePlus");G+=O("","SizeMinus");G+=bf;G+=O("","Print");G+=bf;G+=O("","About");G+=O("","Site");height=208;break;case "table":G+=eN("TableInsert");G+=eN("TableProp");G+=bf;G+=eN("TableCell");break;case "form":G+=bb("FormText","InsertInputText");G+=bb("FormTextArea","InsertTextArea");G+=bb("FormRadio","InsertInputRadio");G+=bb("FormCheckbox","InsertInputCheckbox");G+=bb("FormDropdown","InsertSelectDropdown");G+=bb("FormButton","InsertButton");break;case "gallery":G+=O("","GalleryImage");G+=O("","GalleryFlash");G+=O("","GalleryMedia");G+=O("","GalleryFile");break;case "zoom":for(var i=0;i<cY.Options.length;i++){if(cY.Options[i]==cY.qr){G+=dY("","cY.Execute("+cY.Options[i]+")",120,cY.Options[i]+"%");}else{G+=dY("","cY.Execute("+cY.Options[i]+")",119,cY.Options[i]+"%");}}break;case "fontsize":var v=C.CP();for(var i=0;i<lang["FontSizeItem"].length;i++){if(lang["FontSizeItem"][i][0]==v){G+=dY("","fq('size','"+lang["FontSizeItem"][i][0]+"')",120,lang["FontSizeItem"][i][1]);}else{G+=dY("","fq('size','"+lang["FontSizeItem"][i][0]+"')",119,lang["FontSizeItem"][i][1]);}}break;case "fontname":var v=EWEB.T.queryCommandValue("FontName");for(var i=0;i<lang["FontNameItem"].length;i++){if(lang["FontNameItem"][i]==v){G+=dY("","fq('face','"+lang["FontNameItem"][i]+"')",120,lang["FontNameItem"][i]);}else{G+=dY("","fq('face','"+lang["FontNameItem"][i]+"')",119,lang["FontNameItem"][i]);}}break;case "formatblock":var v=EWEB.T.queryCommandValue("FormatBlock");if(v){v=v.toLowerCase();}else{v="";}for(var i=0;i<lang["FormatBlockItem"].length;i++){if(lang["FormatBlockItem"][i][0].toLowerCase()==v){G+=dY("","format('FormatBlock','"+lang["FormatBlockItem"][i][0]+"')",120,lang["FormatBlockItem"][i][1]);}else{G+=dY("","format('FormatBlock','"+lang["FormatBlockItem"][i][0]+"')",119,lang["FormatBlockItem"][i][1]);}}break;}eA.innerHTML=kp+G+kg;if(cv){cv.show(0,0,0,0,document.body);e=window.event;e.returnValue=false;var el=e.srcElement;var x=e.clientX-e.offsetX;var y=e.clientY-e.offsetY;if(el.style.top){y=y-parseInt(el.style.top);}if(el.tagName.toLowerCase()=="img"){el=el.parentNode;x=x-el.offsetLeft-el.clientLeft;y=y-el.offsetTop-el.clientTop;}if(el.className=="TB_Btn_Image"){el=el.parentNode;x=x-el.offsetLeft-el.clientLeft;y=y-el.offsetTop-el.clientTop;}y=y+el.offsetHeight;var ew=parseInt(el.offsetWidth);bH.x=x;bH.y=y;bH.ew=ew;bH.rel=R.fR(document)?document.documentElement:document.body;am.Show();}else{var el=e.target;if(el.tagName.toLowerCase()=="img"||el.className=="TB_Btn_Image"){el=el.parentNode;}var x=0;var y=0;var ew=el.offsetWidth;var gK=el;if(F.ik){x=e.clientX;y=e.clientY;}else{x=e.pageX;y=e.pageY;}var fs=R.hg(cN,el);x=fs.x;y=fs.y+el.offsetHeight;bH.x=x;bH.y=y;bH.ew=ew;aP.contentWindow.focus();window.setTimeout("am.Show()",1);}},rw:function(e){if(EWEB.ae!="EDIT"){return R.aw(e);}mv();if(gg){am.Hide();}var G="";G+=bb("Cut");G+=bb("Copy");G+=O("","Paste");G+=bb("Delete");G+=bb("SelectAll");G+=bf;if(bI.bp()){G+=eN("TableProp");G+=eN("TableCell");G+=bf;}if(mV("TABLE")){G+=eN("TableProp");G+=bf;}if(mV("IMG")){var da=aE.wv();if(!da){G+=O("","Image","CMenuImg");G+=bf;G+=O("","zIndexForward");G+=O("","zIndexBackward");G+=bf;}if(da=="flash"){G+=O("","Flash","CMenuFlash");G+=bf;}if(da=="mediaplayer6"||da=="mediaplayer7"||da=="realplayer"||da=="quicktime"||da=="flv"){G+=O("","Media","CMenuMedia");G+=bf;}}if(mV("HR")){G+=O("","HorizontalRule","CMenuHr");G+=bf;}if(iY()){G+=O("","ParagraphAttr","CMenuParagraph");G+=bf;}G+=O("","FindReplace");eA.innerHTML=kp+G+kg;if(cv){cv.show(0,0,0,0,document.body);e=eWebEditor.event;bH.x=e.clientX;bH.y=e.clientY;bH.ew=0;bH.rel=R.fR(EWEB.T)?EWEB.T.documentElement:EWEB.T.body;am.Show();}else{R.aw(e);bH.x=e.pageX;bH.y=e.pageY;var el=EWEB.T;var fs=R.hg(cN,(R.fR(el)?el.documentElement:el.body));bH.x+=fs.x;bH.y+=fs.y;bH.ew=0;aP.contentWindow.focus();window.setTimeout("am.Show()",1);}return false;},Hide:function(){if(cv){cv.hide();}else{if(!gg){return;}aP.style.width=aP.style.height='0px';gg=false;}}};})();function sF(e){};function rK(e){am.Hide();};var ec=(function(){var eP;var us=9999;var cB;var fK;var cN;var cg;var ks=function(){return++us;};var oH=function(){if(!cB){return;}var gK=R.fR(cg)?cg.documentElement:cg.body;R.cP(cB,{'width':Math.max(gK.scrollWidth,gK.clientWidth,cg.scrollWidth||0)-1+'px','height':Math.max(gK.scrollHeight,gK.clientHeight,cg.scrollHeight||0)-1+'px'});};var pj=function(el){R.cP(el,{'zIndex':ks()});};var tu=function(){if(!cN){cN=R.lJ();cg=cN.document;}cB=cg.createElement("div");R.hh(cB);R.cP(cB,{"position":"absolute","zIndex":ks(),"top":"0px","left":"0px","backgroundColor":"#ffffff"});R.rN(cB,0.50);if(F.as&& !F.gB){fK=cg.createElement("iframe");R.hh(fK);fK.hideFocus=true;fK.frameBorder=0;fK.src=R.iO();R.cP(fK,{"width":"100%","height":"100%","position":"absolute","left":"0px","top":"0px","filter":"progid:DXImageTransform.Microsoft.Alpha(opacity=0)"});cB.appendChild(fK);}R.az(cN,"resize",oH);oH();cg.body.appendChild(cB);};var uW=function(){R.cE(cB);};return{OpenDialog:function(rz,fP){if(!eP){tu();}else{pj(cB);}var tI={vz:cN,aR:window,Page:rz,Hide:fP};C.Save(true);var ei=160;var cq=100;var dialog=cg.createElement('iframe');R.hh(dialog);dialog.frameBorder=0;dialog.allowTransparency=true;var sJ=F.as&&(!F.gB|| !R.fR(cN.document));R.cP(dialog,{'position':(sJ)?'absolute':'fixed','width':ei+'px','height':cq+'px','zIndex':ks()});if(fP){R.cP(dialog,{'top':'-10000px','left':'-10000px'});}else{this.oP(dialog,ei,cq);}dialog.src=EWEB.cd+"/dialog/dialog.htm";dialog.kw=tI;cg.body.appendChild(dialog);dialog.la=eP;eP=dialog;},wH:function(wd){var dialog=wd.frameElement;R.cE(dialog);if(dialog.la){eP=dialog.la;pj(eP);}else{uW();setTimeout(function(){eP=null;},0);C.Release();}},oP:function(dialog,ei,cq){if(!ei){ei=parseInt(dialog.style.width,10);}if(!cq){cq=parseInt(dialog.style.height,10);}var oh=R.eF(cN);var kc={'X':0,'Y':0};var uS=F.as&&(!F.gB|| !R.fR(cN.document));if(uS){kc=R.gL(cN);}var dM=Math.max(kc.Y+(oh.Height-cq-20)/2,0);var jq=Math.max(kc.X+(oh.Width-ei-20)/2,0);R.cP(dialog,{'top':dM+'px','left':jq+'px'});},yH:function(){return cB;},Ab:function(){return eP;}};})();var ci=(function(){var tW=function(dW){dW.onmouseover=tY;dW.onmouseout=vg;dW.onmousedown=uJ;dW.onmouseup=tZ;dW.ondragstart=R.aw;dW.onselectstart=R.aw;dW.onselect=R.aw;dW.qn=true;return true;};var jv=function(e){if(!e){e=window.event;}var el=e.srcElement||e.target;if(el.tagName=="IMG"){el=el.parentNode;}if(el.className=="TB_Btn_Image"){el=el.parentNode;}return el;};var tY=function(e){var el=jv(e);el.className="TB_Btn_Over";};var vg=function(e){var el=jv(e);if(el.dj){el.className="TB_Btn_Down";}else{el.className="TB_Btn";}};var uJ=function(e){var el=jv(e);el.className="TB_Btn_Down";};var tZ=function(e){var el=jv(e);if(el.className="TB_Btn_Down"){el.className="TB_Btn_Over";}else{if(el.dj){el.className="TB_Btn_Down";}else{el.className="TB_Btn";}}};var eV;var kT=function(){if(eV){return;}var oa={normal:["Bold","Italic","UnderLine","StrikeThrough","SuperScript","SubScript","JustifyLeft","JustifyCenter","JustifyRight","JustifyFull"],mode:["ModeCode","ModeEdit","ModeView","ModeText"],other:["ShowBlocks","ShowBorders","Maximize","FormatBrush"]};var K=$("eWebEditor_Toolbar").getElementsByTagName("DIV");eV=new Object;for(gM in oa){var oD=oa[gM];var iH=new Object;for(var i=0;i<oD.length;i++){var aV=oD[i];iH[aV]=new Array();for(var j=0;j<K.length;j++){var el=K[j];if(el.getAttribute("name")=="TB_Name_"+aV){iH[aV][iH[aV].length]=el;}}}eV[gM]=iH;}};var tJ=function(gV){kT();var fl="";if(F.as&&C.ai()!="Control"){var p=C.lF(["P","DIV","TD","TH"]);if(p){fl=p.style.textAlign;if(!fl){fl=p.getAttribute("align");}}}var hi=eV["normal"];for(aV in hi){var v;if(fl&&aV.substring(0,7)=="Justify"){var ab=aV.substr(7).toLowerCase();if(ab=="full"){ab="justify";}if(fl.toLowerCase()==ab){v=fl;}else{v="";}}else{v=EWEB.T.queryCommandState(aV);}var K=hi[aV];for(var j=0;j<K.length;j++){var el=K[j];el.dj=v;if(gV){el.className="TB_Btn";}else{if(v){el.className="TB_Btn_Down";}else{el.className="TB_Btn";}}}}};var sj=function(){kT();var hi=eV["mode"];for(aV in hi){var K=hi[aV];for(var j=0;j<K.length;j++){var el=K[j];var ay=el.getAttribute("name");ay=ay.substr(ay.length-4).toUpperCase();if(ay==EWEB.ae){el.dj="on";el.className="TB_Btn_Down";}else{el.dj="";el.className="TB_Btn";}}}};var tN=function(gV){var en,v;en="FontName";if(gV){v="";}else{v=EWEB.T.queryCommandValue(en);}nQ(en,v);en="FontSize";v=C.CP();nQ(en,v);};var nQ=function(en,v){var K=document.getElementsByName("TB_Name_"+en);for(var i=0;i<K.length;i++){var el=K[i];if(v){v=v.toLowerCase();v=v.replace(/[\'\"]/gi,'');var b=false;for(var j=0;j<el.options.length;j++){var pn=el.options[j].value.toLowerCase();if(pn==v||(en=="FontSize"&&uV(pn,v))){el.selectedIndex=j;b=true;break;}}if(!b){el.options[el.options.length]=new Option(v,v);el.selectedIndex=el.options.length-1;}}else{el.selectedIndex=0;}}};var uV=function(ab,aF){ab=ab.toLowerCase();aF=aF.toLowerCase();if(ab==aF){return true;}if(ab.eg("pt")&&aF.eg("px")){var gj=0;ab=parseFloat(ab)+"";var n=ab.indexOf(".");if(n>=0){var s=ab.substr(n+1);gj=s.length;}if(gj>0){if(ab==Math.round(parseFloat(aF)*3/4*Math.pow(10,gj)+0.01)/Math.pow(10,gj)){return true;}}else{if(ab==parseInt(parseFloat(aF)*3/4+0.01)){return true;}}}return false;};return{vF:function(){var i,K,el,p;p=$("eWebEditor_Toolbar");K=p.getElementsByTagName("div");for(i=0;i<K.length;i++){el=K[i];if(el.className=="TB_Btn"){if(el.qn==null){if(!tW(el)){ec.OpenDialog("prompt.htm?prompt=Problem initializing:"+el.id);return false;}}}}return true;},eW:function(){if(EWEB.ae!="EDIT"){return;}var b=(C.ai()=="Control")?true:false;tJ(b);tN(b);},rk:function(){sj();},hV:function(gM,rI){kT();return eV[gM][rI];}};})();var bI=(function(){var aS;var au;var nS;var dk;return{bp:function(){if(C.ai()!="Control"){var el=C.cI();while(el){if(!el.tagName){el=null;break;}if(el.tagName.toUpperCase()=="TD"||el.tagName.toUpperCase()=="TH"){break;}else if(el.tagName.toUpperCase()=="BODY"||el.tagName.toUpperCase()=="HTML"){el=null;break;}el=el.parentNode;}if(el){aS=el;au=aS.parentNode;nS=au.parentNode;dk=nS.parentNode;return true;}}return false;},gl:function(){if(C.ai()=="Control"){var el=C.ax();if(el.tagName.toUpperCase()=="TABLE"){dk=el;return true;}}return false;},TableInsert:function(){if(!bI.gl()){aK('table.htm',true);}},TableProp:function(){if(bI.gl()||bI.bp()){aK('table.htm?action=modify',true);}},tK:function(){if(bI.bp()){aK('tablecell.htm',true);}},uC:function(){if(bI.bp()){aK('tablecellsplit.htm',true);}},sT:function(){if(bI.bp()){aK('tablecell.htm?action=row',true);}},qt:function(){if(!bI.bp()){return;}ap.Save();var cQ=0;cz=au.cells;for(var i=0;i<cz.length;i++){cQ=cQ+cz[i].getAttribute('colSpan');}var gu=dk.insertRow(au.rowIndex);for(i=0;i<cQ;i++){fL=gu.insertCell(-1);fL.innerHTML="&nbsp;";}ap.Save();},sR:function(){if(!bI.bp()){return;}ap.Save();var cQ=0;cz=au.cells;for(var i=0;i<cz.length;i++){cQ=cQ+cz[i].getAttribute('colSpan');}var gu=dk.insertRow(au.rowIndex+1);for(i=0;i<cQ;i++){fL=gu.insertCell(-1);fL.innerHTML="&nbsp;";}ap.Save();},rv:function(){if(!bI.bp()){return;}ap.Save();var ze=aS.getAttribute('rowSpan');ba=dk.rows;if(au.rowIndex+1!=ba.length){var rq=ba[au.rowIndex+aS.rowSpan].cells;var lx=rq[aS.cellIndex].getAttribute('rowSpan');var moveTo=aS.rowSpan;if(!lx)lx=1;aS.rowSpan=aS.rowSpan+lx;ba[au.rowIndex+moveTo].deleteCell(aS.cellIndex);}ap.Save();},pI:function(mu){if(!bI.bp()){return;}if(mu<2){return;}ap.Save();var sC=mu-1;var jQ=sC;var gp=0;for(var i=0;i<aS.cellIndex;i++){gp+=au.cells[i].colSpan;}var ba=dk.rows;while(aS.rowSpan>1&&jQ>0){var kM=ba[au.rowIndex+aS.rowSpan-1];aS.rowSpan-=1;var gJ=0;var position= -1;for(var n=0;n<kM.cells.length;n++){gJ+=kM.cells[n].getAttribute('colSpan');if(gJ>gp){position=n;break;}}var fL=kM.insertCell(position);fL.innerHTML="&nbsp;";jQ-=1;}for(var n=0;n<jQ;n++){var cQ=0;cz=au.cells;for(var i=0;i<cz.length;i++){cQ=cQ+cz[i].getAttribute('colSpan');}var gu=dk.insertRow(au.rowIndex+1);for(var j=0;j<au.rowIndex;j++){for(var k=0;k<ba[j].cells.length;k++){if((ba[j].cells[k].rowSpan>1)&&(ba[j].cells[k].rowSpan>=au.rowIndex-ba[j].rowIndex+1)){ba[j].cells[k].rowSpan+=1;}}}for(i=0;i<cz.length;i++){if(i!=aS.cellIndex){au.cells[i].rowSpan+=1;}else{fL=gu.insertCell(-1);fL.colSpan=aS.colSpan;fL.innerHTML="&nbsp;";}}}ap.Save();},qa:function(){if(!bI.bp()){return;}ap.Save();dk.deleteRow(au.rowIndex);ap.Save();},sf:function(){if(!bI.bp()){return;}ap.Save();hy=(au.cells.length-1)-(aS.cellIndex);ba=dk.rows;for(i=0;i<ba.length;i++){kq=ba[i].cells.length-1;position=kq-hy;if(position<0){position=0;}dN=ba[i].insertCell(position);dN.innerHTML="&nbsp;";}ap.Save();},sK:function(){if(!bI.bp()){return;}ap.Save();hy=(au.cells.length-1)-(aS.cellIndex);ba=dk.rows;for(i=0;i<ba.length;i++){kq=ba[i].cells.length-1;position=kq-hy;if(position<0){position=0;}dN=ba[i].insertCell(position+1);dN.innerHTML="&nbsp;";}ap.Save();},sq:function(){if(!bI.bp()){return;}ap.Save();var sH=aS.getAttribute('colSpan');cz=au.cells;if(aS.cellIndex+1!=au.cells.length){var ru=cz[aS.cellIndex+1].getAttribute('colSpan');aS.colSpan=sH+ru;au.deleteCell(aS.cellIndex+1);}ap.Save();},rX:function(){if(!bI.bp()){return;}ap.Save();hy=(au.cells.length-1)-(aS.cellIndex);ba=dk.rows;for(var i=0;i<ba.length;i++){vE=ba[i].cells.length-1;position=vE-hy;if(position<0){position=0;}kl=ba[i].cells;if(kl[position].colSpan>1){kl[position].colSpan=kl[position].colSpan-1;}else{ba[i].deleteCell(position);}}ap.Save();},qY:function(mJ){if(!bI.bp()){return;}if(mJ<2){return;}ap.Save();var sS=mJ-1;var hb=sS;var dN;var gp=0;var lb=0;for(var i=0;i<aS.cellIndex;i++){gp+=au.cells[i].colSpan;if(au.cells[i].rowSpan>1){lb+=1;}}var ba=dk.rows;while(aS.colSpan>1&&hb>0){dN=au.insertCell(aS.cellIndex+1);dN.innerHTML="&nbsp;";aS.colSpan-=1;hb-=1;}for(i=0;i<ba.length;i++){var gJ=0;var position= -1;for(var n=0;n<ba[i].cells.length;n++){gJ+=ba[i].cells[n].getAttribute('colSpan');if(gJ+lb>gp){position=n;break;}}if(au.rowIndex!=i){if(position!= -1){ba[i].cells[position+lb].colSpan+=hb;}}else{for(var n=0;n<hb;n++){dN=ba[i].insertCell(aS.cellIndex+1);dN.innerHTML="&nbsp;";dN.rowSpan=aS.rowSpan;}}}ap.Save();}};})();var cW=(function(){var oy=2;var or=5;var df=false;var dQ=false;var fj=false;var dz=null;var kj=0;var nF=0;var cU=null;var nC=0;var lB=0;var ot;var po;var nN;var op;var kA;var lk;var cJ=null;var av=null;var jd=null;var ma;var mt;var nx;var mT;var hc=new Array();var hK=new Array();var gf=new Array();var iL=new Array();var nX=false;var ur=function(){dz=$("div_TableResizeSepV");dz.className="TableResizeSepV";cU=$("div_TableResizeSepH");cU.className="TableResizeSepH";R.az(document,'mousemove',cW.PMM);nX=true;};var ee=function(){df=false;dQ=false;fj=false;cJ=null;av=null;jd=null;hc.length=0;hK.length=0;gf.length=0;iL.length=0;dz.style.display="none";cU.style.display="none";};var tL=function(be){var n=be.offsetWidth;n=n-jF(R.ce(be,"padding-left"));n=n-jF(R.ce(be,"padding-right"));return n;};var uZ=function(be){var n=be.offsetHeight;n=n-jF(R.ce(be,"padding-top"));n=n-jF(R.ce(be,"padding-bottom"));return n;};var lP=function(be){if(isNaN(parseInt(be.rowSpan))){return 1;}else{return parseInt(be.rowSpan);}};var jF=function(bv){if(!bv){return 0;}if(isNaN(parseInt(bv))){return 0;}bv=bv.toLowerCase();if(parseFloat(bv)==0){return 0;}else if(bv.eg("px")){return parseInt(bv);}else if(bv.eg("pt")){return parseInt(parseFloat(bv)*4/3);}else if(bv.eg("cm")){return parseInt(parseFloat(bv)*28.55*4/3);}else if(bv.eg("mm")){return parseInt(parseFloat(bv)*0.001*28.55*4/3);}else{return 0;}};var pp=function(){dz.style.display="none";cU.style.display="none";if(df){dz.style.cursor="e-resize";dz.style.display="";}if(dQ){cU.style.cursor="s-resize";cU.style.display="";}if(df&&dQ){dz.style.cursor="se-resize";cU.style.cursor="se-resize";}};return{xf:function(){return fj;},MM:function(e){if(fj){this.MM2(e);return;}if(!nX){ur();}ee();var el=e.srcElement||e.target;while(el.tagName.toUpperCase()!="TD"&&el.tagName.toUpperCase()!="TH"){if(el.tagName.toUpperCase()=="BODY"||el.tagName.toUpperCase()=="HTML"){ee();return;}el=el.parentNode;if(!el){ee();return;}}cJ=el;var jq=0;var dM=0;while(el){jq+=el.offsetLeft;dM+=el.offsetTop;el=el.offsetParent;}var oW=R.gL(EWEB.aR);var mf=jq+cJ.offsetWidth-oW.X;nN=e.screenX-e.clientX;kA=mf-oy;if(e.clientX>kA){df=true;}var mo=dM+cJ.offsetHeight-oW.Y;op=e.screenY-e.clientY;lk=mo-oy;if(e.clientY>lk){dQ=true;}if(df||dQ){kj=mf+$("eWebEditor").offsetLeft+$("eWebEditor_Layout").offsetLeft;nF=$("eWebEditor").offsetTop+$("eWebEditor_Layout").offsetTop+$("eWebEditor_ToolarPTR").offsetHeight;dz.style.left=kj+"px";dz.style.top=nF+"px";dz.style.width=or+"px";dz.style.height=$("eWebEditor").offsetHeight+"px";nC=$("eWebEditor").offsetLeft+$("eWebEditor_Layout").offsetLeft;lB=mo+$("eWebEditor").offsetTop+$("eWebEditor_Layout").offsetTop+$("eWebEditor_ToolarPTR").offsetHeight;cU.style.left=nC+"px";cU.style.top=lB+"px";cU.style.width=$("eWebEditor").offsetWidth+"px";cU.style.height=or+"px";}pp();},MD2:function(e){if(!e){e=eWebEditor.event;}if(F.as&&e.button!=1){return;}fj=true;ot=e.screenX;po=e.screenY;av=R.tz(cJ,"TABLE");if(df){mt=av.offsetWidth;av.style.width=av.offsetWidth;ma=cJ.offsetWidth;for(var i=0;i<av.rows.length;i++){for(var j=0;j<av.rows[i].cells.length;j++){var be=av.rows[i].cells[j];be.style.width=tL(be);be.removeAttribute("width");}}hc.length=0;hK.length=0;var n=0;for(var i=0;i<av.rows.length;i++){for(var j=0;j<av.rows[i].cells.length;j++){var be=av.rows[i].cells[j];if((be.offsetLeft+be.offsetWidth)>=(cJ.offsetLeft+cJ.offsetWidth)&&(be.offsetLeft<(cJ.offsetLeft+cJ.offsetWidth))){hc[n]=be;hK[n]=parseInt(be.style.width);n++;break;}}}}if(dQ){jd=cJ.parentNode;nx=av.offsetHeight;av.style.height=av.offsetHeight;mT=cJ.offsetHeight;for(var i=0;i<av.rows.length;i++){for(var j=0;j<av.rows[i].cells.length;j++){var be=av.rows[i].cells[j];be.style.height=uZ(be);be.removeAttribute("height");}}gf.length=0;iL.length=0;var n=0;var lf=jd.rowIndex+lP(jd);for(var i=0;i<lf;i++){for(var j=0;j<av.rows[i].cells.length;j++){var be=av.rows[i].cells[j];if((lP(be)+i)>=lf&&i<lf){gf[n]=be;iL[n]=parseInt(be.style.height);n++;}}}}},MM2:function(e){if(!e){e=eWebEditor.event;}if(F.as&&e.button!=1&&fj){ee();}if(!fj){var fU=false;if(e.screenX-nN>kA){if(!df){fU=true;df=true;}}else{if(df){fU=true;df=false;}}if(e.screenY-op>lk){if(!dQ){fU=true;dQ=true;}}else{if(dQ){fU=true;dQ=false;}}if(fU){pp();}return;}if(df){var eK=e.screenX-ot;var gD=eK;if(av.align.toLowerCase()=="center"){gD=2*gD;}var uQ=gD+ma;var tP=gD+mt;if(uQ>=2){av.style.width=tP+"px";dz.style.left=(kj+eK)+"px";for(var i=0;i<hc.length;i++){try{hc[i].style.width=(gD+hK[i])+"px";}catch(er){}}}}if(dQ){var eK=e.screenY-po;var vu=eK+mT;var uw=eK+nx;if(vu>=2){av.style.height=uw+"px";cU.style.top=(lB+eK)+"px";for(var i=0;i<gf.length;i++){try{gf[i].style.height=(eK+iL[i])+"px";}catch(er){}}}}},MU2:function(e){if(!fj){return;}ee();},PMM:function(e){if(!e){e=window.event;}if(F.as&&e.button!=1&&fj){ee();}}};})();var ap=(function(){var dm=[];var dv=0;var dR=[];var ha=false;var ox=function(){var lw=dR[dv];if(lw){if(F.as){eWebEditor_Layout.focus();if(lw.substring(0,8)!="[object]"){var r=EWEB.T.body.createTextRange();if(r.moveToBookmark(dR[dv])){r.select();}}else{if(EWEB.ae=="EDIT"){var r=EWEB.T.body.createControlRange();var a=lw.split("|");var K=EWEB.T.body.getElementsByTagName(a[1]);var el=K[a[2]];r.addElement(el);r.select();}}}else{}}};var tq=function(el){var K=EWEB.T.body.getElementsByTagName(el.tagName);for(var i=0;i<K.length;i++){if(K[i]==el){return i;}}return null;};return{rs:function(){if(dm.length<=1||dv<=0){return false;}return true;},rC:function(){if(dv>=dm.length-1||dm.length==0){return false;}return true;},jO:function(){ha=false;},Save:function(){if(ha){return;}ha=true;var V=getHTML();if(dm[dv]==V){return;}var wa=dm.length;var ws=dm.length-dv;for(var i=1;i<ws;i++){dm.pop();dR.pop();}dm[dm.length]=V;if(F.as){if(C.ai()!="Control"){try{dR[dR.length]=EWEB.T.selection.createRange().getBookmark();}catch(e){dR[dR.length]="";}}else{var el=C.ax();dR[dR.length]="[object]|"+el.tagName+"|"+tq(el);}}else{try{dR[dR.length]=EWEB.aR.getSelection().getRangeAt(0).endContainer;}catch(e){dR[dR.length]="";}}if(wa!=0){dv++;}},Go:function(v){if(!ha){this.Save();}if(v== -1){if(dv>0){dv=dv-1;setHTML(dm[dv],true);ox();}}else{if(dv<dm.length-1){dv=dv+1;setHTML(dm[dv],true);ox();}}EWEB.Focus();ci.eW();}};})();var aZ;function eY(ri){if(aZ){return true;}var b=false;try{aZ=new ActiveXObject("eWebSoft.eWebEditor3");var oC=aZ.Version;if(parseFloat(oC.replace(/[^0123456789]+/gi,""))>=3600){aZ.Lang=lang.bF;aZ.SendUrl=EWEB.SendUrl;aZ.LocalSize=config.AllowLocalSize;aZ.LocalExt=config.AllowLocalExt;b=true;}}catch(e){}if(!b&&ri){aZ=null;aK("installactivex.htm",true);}return b;};function es(){var dU=aZ.Error;if(dU!=""){var fX,ge;if(dU.indexOf(":")>=0){var a=dU.split(":");fX=a[0];ge=a[1];}else{fX=dU;ge="";}switch(fX){case "L":ec.OpenDialog("prompt.htm?prompt="+lang["ErrLicense"]);break;case "InvalidFile":ec.OpenDialog("prompt.htm?prompt="+lang["ErrInvalidFile"]+":"+ge);break;default:ec.OpenDialog("prompt.htm?prompt="+dU);}return true;}return false;};function exec(iA,iQ){EWEB.Focus();iA=iA.toLowerCase();switch(iA){case 'undo':ap.Go(-1);break;case 'redo':ap.Go(1);break;case 'cut':kC.Execute('Cut');break;case 'copy':kC.Execute('Copy');break;case 'paste':oX();break;case 'pastetext':ix();break;case 'pasteword':kF();break;case 'delete':format('delete');break;case 'removeformat':format('RemoveFormat');break;case 'selectall':format('selectall');break;case 'unselect':format('unselect');break;case 'findreplace':qu();break;case 'spellcheck':uT();break;case 'quickformat':if(config.AutoDoneQuickFormat){aK("quickformat.htm?autodone=1",true,false,true);}else{aK("quickformat.htm",true);}break;case 'formatbrush':CL.Execute();break;case 'bold':format('bold');break;case 'italic':format('italic');break;case 'underline':format('underline');break;case 'strikethrough':format('StrikeThrough');break;case 'superscript':format('superscript');break;case 'subscript':format('subscript');break;case 'uppercase':pl('uppercase');break;case 'lowercase':pl('lowercase');break;case 'forecolor':aK('selcolor.htm?action=forecolor',true);break;case 'backcolor':aK('selcolor.htm?action=backcolor',true);break;case 'big':dB('big');break;case 'small':dB('small');break;case 'justifyleft':hZ.Execute('justifyleft');break;case 'justifycenter':hZ.Execute('justifycenter');break;case 'justifyright':hZ.Execute('justifyright');break;case 'justifyfull':hZ.Execute('justifyfull');break;case 'orderedlist':format('insertorderedlist');break;case 'unorderedlist':format('insertunorderedlist');break;case 'indent':format('indent');break;case 'outdent':format('outdent');break;case 'br':dB('br');break;case 'paragraph':format('InsertParagraph');break;case 'paragraphattr':tM();break;case 'image':aK('img.htm',true);break;case 'flash':aK('flash.htm',true);break;case 'media':aK('media.htm',true);break;case 'file':aK('file.htm',true);break;case 'remoteupload':remoteUpload();break;case 'localupload':localUpload();break;case 'fieldset':aK('fieldset.htm',true);break;case 'iframe':aK('iframe.htm',true);break;case 'horizontalrule':aK('hr.htm',true);break;case 'marquee':aK('marquee.htm',true);break;case 'createlink':uB();break;case 'unlink':format('UnLink');break;case 'map':tQ();break;case 'anchor':aK('anchor.htm',true);break;case 'galleryimage':aK('browse.htm?type=image',true);break;case 'galleryflash':aK('browse.htm?type=flash',true);break;case 'gallerymedia':aK('browse.htm?type=media',true);break;case 'galleryfile':aK('browse.htm?type=file',true);break;case 'bgcolor':aK('selcolor.htm?action=bgcolor',true);break;case 'backimage':aK('backimage.htm',true);break;case 'absoluteposition':uD();break;case 'zindexbackward':pe('backward');break;case 'zindexforward':pe('forward');break;case 'showborders':kh.Execute();break;case 'showblocks':jK.Execute();break;case 'quote':dB('quote');break;case 'code':dB('code');break;case 'symbol':aK('symbol.htm',true);break;case 'printbreak':dB('printbreak');break;case 'excel':aK('owcexcel.htm',true,true);break;case 'emot':aK('emot.htm',true);break;case 'eq':aK('eq.htm',true);break;case 'art':aK('art.htm',true,true);break;case 'nowdate':dB('nowdate');break;case 'nowtime':dB('nowtime');break;case 'importword':ow('word');break;case 'importexcel':ow('excel');break;case 'template':aK('template.htm',true);break;case 'capture':ue();break;case 'pagination':aK('pagination.htm',true);break;case 'paginationinsert':dp.fv();break;case 'formtext':eO.fv('inputtext');break;case 'formtextarea':eO.fv('textarea');break;case 'formradio':eO.fv('radio');break;case 'formcheckbox':eO.fv('checkbox');break;case 'formdropdown':eO.fv('select');break;case 'formbutton':eO.fv('button');break;case 'tableinsert':bI.TableInsert();break;case 'tableprop':bI.TableProp();break;case 'tablecellprop':bI.tK();break;case 'tablecellsplit':bI.uC();break;case 'tablerowprop':bI.sT();break;case 'tablerowinsertabove':bI.qt();break;case 'tablerowinsertbelow':bI.sR();break;case 'tablerowmerge':bI.rv();break;case 'tablerowsplit':bI.pI(2);break;case 'tablerowdelete':bI.qa();break;case 'tablecolinsertleft':bI.sf();break;case 'tablecolinsertright':bI.sK();break;case 'tablecolmerge':bI.sq();break;case 'tablecolsplit':bI.qY(2);break;case 'tablecoldelete':bI.rX();break;case 'refresh':setHTML('');break;case 'modecode':setMode('CODE');break;case 'modeedit':setMode('EDIT');break;case 'modetext':setMode('TEXT');break;case 'modeview':setMode('VIEW');break;case 'sizeplus':ej(300);break;case 'sizeminus':ej(-300);break;case 'print':tp();break;case 'maximize':kQ.Execute();break;case 'minimize':parent.Minimize();break;case 'help':aK('help.htm');break;case 'about':aK('about.htm');break;case 'site':window.open('http://www.ewebeditor.net');break;case 'fontface':fq('face',iQ);break;case 'fontsize':fq('size',iQ);break;case 'formatblock':format('FormatBlock',iQ);break;case 'zoom':cY.Execute(iQ);break;}};var EWEB={T:null,aR:null,ae:null,bs:null,BaseHref:"",cd:"",hW:"",SendUrl:"",ReadyState:"",Focus:function(){if(EWEB.ae=="CODE"||EWEB.ae=="TEXT"){EWEB.db.focus();return;}if(F.as){if(config.FixWidth){if(document.activeElement.id!="eWebEditor"){eWebEditor.focus();}try{var aD=EWEB.T.selection.createRange();if(aD.parentElement().tagName=="BODY"){aD.moveToElementText(EWEB.T.getElementById("eWebEditor_FixWidth_DIV"));aD.collapse(true);aD.select();}else{aD.select();}}catch(e){}}else{eWebEditor.focus();}}else{this.aR.focus();}},Init:function(){if(!config.L){return;}if(!F.iF){return;}this.hW=document.location.protocol.toLowerCase()+"//"+document.location.host;var s=document.location.pathname;this.cd=s.substr(0,s.length-15);this.BaseHref="";if(config.BaseHref!=""){this.BaseHref="<base href='"+this.hW+config.BaseHref+"'></base>";}if(aA.ExtCSS){this.ExtCSS="<link href='"+uN(aA.ExtCSS)+"' type='text/css' rel='stylesheet'>";}else{this.ExtCSS="";}if(aA.Skin){config.Skin=aA.Skin;}if(aA.FixWidth){config.FixWidth=aA.FixWidth;}if(aA.AreaCssMode){config.AreaCssMode=aA.AreaCssMode;}if(aA.ReadOnly){config.InitMode="VIEW";}this.SendUrl=this.hW+this.cd+"/"+config.ServerExt+"/upload."+config.ServerExt+"?style="+aA.StyleName+"&cusdir="+aA.CusDir+"&sparams="+config.SParams+"&skey="+aA.SKey+"&h="+aA.H;R.az(document,'contextmenu',jt);R.az(document,'dragstart',jt);R.az(document,'selectstart',jt);R.az(document,'select',jt);if((F.jo||F.nb)&& !F.jr){window.onresize=function(e){kf();};}}};function focus(){EWEB.Focus();};function setReadOnly(dF){if(dF!="1"&&dF!="2"){dF="";}EWEB.ReadOnly=EWEB.ReadOnly||"";if(EWEB.ReadOnly==dF){return;}var hI=$("eWebEditor_SB");var mF=$("eWebEditor_SB_Mode");if(hI){switch(dF){case "1":hI.style.display="";mF.style.display="none";break;case "2":hI.style.display="none";break;default:hI.style.display="";mF.style.display="";}}EWEB.ReadOnly=dF;if(EWEB.ReadyState=="complete"){if(dF==""){setMode("EDIT");}else{setMode("VIEW");}}};EWEB.lo=function(){var pz=this.T;if(F.as){if(config.FixWidth){pz.body.contentEditable=false;var cR=pz.getElementById("eWebEditor_FixWidth_DIV");cR.contentEditable=true;}else{pz.body.contentEditable=true;}pz.execCommand("2D-Position",true,true);}else{try{pz.designMode='on';pz.execCommand("styleWithCSS",false,"true");pz.execCommand("enableInlineTableEditing",false,"false");if(config.EnterMode=="2"){pz.execCommand("insertBrOnReturn",false,"true");}if(config.FixWidth){pz.designMode='off';var cR=pz.getElementById("eWebEditor_FixWidth_DIV");cR.contentEditable="true";}}catch(e){R.az(this.aR.frameElement,'DOMAttrModified',qX);}}};function qX(evt){if(EWEB.kv){window.clearTimeout(EWEB.kv);}EWEB.kv=R.oQ(sa,1000,EWEB);};function sa(){delete this.kv;R.hf(this.aR.frameElement,'DOMAttrModified',qX);this.lo();};function jt(e){if(EWEB.ae=="EDIT"||EWEB.ae=="VIEW"){return R.aw(e);}};function kf(){var ifr_Editarea=$('eWebEditor');if(ifr_Editarea){var nr=ifr_Editarea.parentNode;ifr_Editarea.style.width=(nr.offsetWidth-4)+'px';ifr_Editarea.style.height=(nr.offsetHeight-4)+'px';ifr_Editarea.style.height='100%';}else{window.setTimeout(kf,10);}};var config=new Object();window.onload=ts;function ts(){if(!config.L){return;}if(EWEB.ReadyState){return;}EWEB.ReadyState="loading";R.lE(window);if(!F.iF){return;}EWEB.bs=parent.document.getElementsByName(aA.bs)[0];if(!EWEB.bs){EWEB.bs=parent.document.getElementById(aA.bs);}if(!EWEB.bs){ec.OpenDialog("prompt.htm?prompt=[EWEBEDITOR] The element with id or name "+aA.bs+" was not found.");return;}if(EWEB.bs.tagName=="TEXTAREA"||EWEB.bs.tagName.substring(0,5)=="INPUT"){EWEB.hq="INPUT";}else{EWEB.hq="OTHER";}if((F.jo||F.nb)&& !F.jr){kf();}ci.vF();R.ko(document.body);if(F.as){}else{$("eWebEditorTextarea").style.MozUserSelect="text";}EWEB.aR=$("eWebEditor").contentWindow;EWEB.T=EWEB.aR.document;EWEB.db=$("eWebEditorTextarea");if(!F.iF){config.InitMode="TEXT";}if($("D_ContentFlag").value=="0"){var qW=(EWEB.hq=="INPUT")?EWEB.bs.value:EWEB.bs.innerHTML;$("D_ContentEdit").value=qW;$("D_ContentLoad").value=qW;$("D_CurrMode").value=config.InitMode;$("D_ContentFlag").value="1";}setReadOnly(aA.ReadOnly);setMode($("D_CurrMode").value,true);tU();if(aA.rD){window.setInterval(qG,1000);}if(F.as){lT();}else{window.setTimeout(lT,200);}};function lT(){EWEB.ReadyState="complete";sk({flag:"LoadComplete"});};function sk(fC){fC.id=aA.vs;fC.linkid=aA.bs;fC.win=window;fC.doc=EWEB.T;try{parent.EWEBEDITOR.EVENT(fC);}catch(e){}var jE;try{jE=parent.EWEBEDITOR_EVENT(fC);}catch(e){}return(jE&&typeof(jE)=="object")?jE:{};};function tU(){if(!EWEB.bs){return;}if(EWEB.hq!="INPUT"){return;}var aO=EWEB.bs.form;if(!aO){return;}R.az(aO,'submit',ie);if(!aO.submitEditor){aO.submitEditor=new Array();}aO.submitEditor[aO.submitEditor.length]=ie;if(!aO.originalSubmit){aO.originalSubmit=aO.submit;aO.submit=function(){if(this.submitEditor){for(var i=0;i<this.submitEditor.length;i++){try{this.submitEditor[i]();}catch(e){}}}this.originalSubmit();};}R.az(aO,'reset',iT);if(!aO.resetEditor)aO.resetEditor=new Array();aO.resetEditor[aO.resetEditor.length]=iT;if(!aO.originalReset){aO.originalReset=aO.reset;aO.reset=function(){if(this.resetEditor){for(var i=0;i<this.resetEditor.length;i++){try{this.resetEditor[i]();}catch(e){}}}this.originalReset();};}};function ie(){var aO=EWEB.bs.form;if(!aO){return;}var V=getHTML();if(config.PaginationMode!="0"&&config.PaginationAutoFlag!="0"){if(EWEB.ae!="EDIT"){setMode("EDIT");}var b=true;if(config.PaginationAutoFlag=="1"){var K=EWEB.T.getElementsByTagName("IMG");for(var i=0;i<K.length;i++){var cb=K[i].getAttribute("_ewebeditor_fake_tag",2);if(cb){if(cb.toLowerCase()=="pagination"){b=false;break;}}}}if(b){dp.Auto(config.PaginationAutoNum);V=getHTML();}}$("D_ContentEdit").value=V;pb(EWEB.bs,V);};function iT(){setHTML($("D_ContentLoad").value);};function uO(){if(EWEB.hq!="INPUT"){return;}var aO=EWEB.bs.form;if(!aO){return;}if(aO.onsubmit){if(aO.onsubmit()){aO.submit();}}else{aO.submit();}};function nM(e){aK('about.htm');return R.aw(e);};function vd(e){if(!e){e=eWebEditor.event;}if(F.as){return R.aw(e);}else{if(config.AutoDetectPaste=="2"){window.setTimeout("ix()",10);return R.aw(e);}ap.Save();return true;}};function sU(e){if(!e){e=eWebEditor.event;}var bK=e.keyCode||e.which;var bA=String.fromCharCode(bK).toUpperCase();if(e.ctrlKey||((bK>=33)&&(bK<=40))||(bK==13)||(bK==8)||(bK==46)){ci.eW();}return true;};function sZ(e){if(!e){e=eWebEditor.event;}var bK=e.keyCode||e.which;var bA=String.fromCharCode(bK).toUpperCase();var bo=false;if(bK==112&& !F.as){aK("about.htm");bo=true;}if(bK==113){kh.Execute();bo=true;}if(bK==114){jK.Execute();bo=true;}if(e.ctrlKey){if(bK==13){uO();bo=true;}if(bK==187||bK==107){ej(300);bo=true;}if(bK==189||bK==109){ej(-300);bo=true;}if(bA=="1"){setMode("CODE");bo=true;}if(bA=="2"){setMode("EDIT");bo=true;}if(bA=="3"){setMode("TEXT");bo=true;}if(bA=="4"){setMode("VIEW");bo=true;}if(bA=="A"){if((EWEB.ae!="CODE")&&(config.FixWidth)){pk();}else{EWEB.Focus();ap.Save();EWEB.T.execCommand("SelectAll",false,null);ap.Save();EWEB.Focus();}bo=true;}if(bA=="D"){kF();bo=true;}if(bA=="R"){qu();bo=true;}if(bA=="Z"){ap.Go(-1);bo=true;}if(bA=="Y"){ap.Go(1);bo=true;}if(bA=="V"&&F.as){window.setTimeout("oX()",10);bo=true;}}if((config.EnterMode=="2")&&(bK==13)&&F.as){ap.Save();ap.jO();var aD=EWEB.T.selection.createRange();if(e.shiftKey){var p=aD.parentElement();if(p.tagName!="P"||p.innerHTML==""){aD.pasteHTML("&nbsp;");aD.select();aD.collapse(false);}try{aD.pasteHTML("</P><P id=eWebEditor_Temp_P>");}catch(err){return false;}e.cancelBubble=true;e.returnValue=false;var el=EWEB.T.getElementById("eWebEditor_Temp_P");if(el.innerHTML==""){el.innerHTML="&nbsp;";}aD.moveToElementText(el);aD.select();aD.collapse(false);aD.select();el.removeAttribute("id");}else{try{aD.pasteHTML("<br>");}catch(err){return false;}e.cancelBubble=true;e.returnValue=false;aD.select();aD.moveEnd("character",1);aD.moveStart("character",1);aD.collapse(false);}bo=true;}if(bo){return R.aw(e);}else{if((bK==13)||(bK==8)||(bK==46)){ap.Save();ap.jO();}else if((bK>=33)&&(bK<=40)){ap.Save();}else if(!((e.ctrlKey&&bA=="A")||(e.ctrlKey&&bA=="F"))){ap.jO();}return true;}};function rU(e){};function rV(e){if(!e){e=eWebEditor.event;}cW.MU2(e);if(e.button!=2){CL.Bi();}ap.Save();ci.eW();};function sr(e){if(!e){e=eWebEditor.event;}cW.MM(e);};function Cv(e){if(CL.Ce()){CL.Stop();}else{am.rw(e);}R.aw(e);return false;};function va(){ap.Save();return true;};function uN(aG){if(aG.indexOf("://")>=0){return aG;}if(aG.substr(0,1)=="/"){return aG;}var gx=EWEB.cd;while(aG.substr(0,3)=="../"){aG=aG.substr(3);gx=gx.substring(0,gx.lastIndexOf("/"));}return gx+"/"+aG;};function insertHTML(V){if(ps()){return;}switch(EWEB.ae){case "EDIT":C.Restore();EWEB.Focus();V=aE.jY(V);if(!window.getSelection){if(EWEB.T.selection.type.toLowerCase()=="control"){EWEB.T.selection.clear();}V='<span id="__ewebeditor_temp_remove__" style="display:none;">eWebEditor</span>'+V;EWEB.T.selection.createRange().pasteHTML(V);EWEB.T.getElementById('__ewebeditor_temp_remove__').removeNode(true);}else{var mW=EWEB.T.createDocumentFragment();var lc=EWEB.T.createElement('div');lc.innerHTML=V;var mz,o_LastNode;while((mz=lc.firstChild)){o_LastNode=mW.appendChild(lc.removeChild(mz));}var Bd=EWEB.aR.getSelection();var fA=Bd.getRangeAt(0);fA.deleteContents();fA.insertNode(mW);if(o_LastNode){fA=fA.cloneRange();fA.setStartAfter(o_LastNode);fA.collapse(true);Bd.removeAllRanges();Bd.addRange(fA);}}ci.eW();break;case "TEXT":case "CODE":EWEB.db.focus();if(F.as){EWEB.T.selection.createRange().text=V;}else{EWEB.db.execCommand("insertHTML",false,V);}break;}};function setHTML(V,ub){$("D_ContentEdit").value=V;switch(EWEB.ae){case "CODE":EWEB.db.value=vy.vi(V);break;case "TEXT":V=V.replace(/<script[^>]*?>(?:[^a]|a)*?<\/script>/gi,"");V=V.replace(/<style[^>]*?>(?:[^a]|a)*?<\/style>/gi,"");V=V.replace(/<object[^>]*?>(?:[^a]|a)*?<\/object>/gi,"");V=V.replace(/<embed[^>]*?>(?:[^a]|a)*?<\/embed>/gi,"");V=V.replace(/<table[^>]*?>(?:[^a]|a)*?<\/table>/gi,"");$("eWebEditor_Temp_HTML").innerHTML=V;if(F.as){V=$("eWebEditor_Temp_HTML").innerText;}else{V=kZ($("eWebEditor_Temp_HTML"));}EWEB.db.value=V;break;case "EDIT":EWEB.T.designMode="on";EWEB.T.open();EWEB.T.write(pG(aE.jY(V)));EWEB.T.close();EWEB.lo();R.az(EWEB.T.body,'paste',vd);R.az(EWEB.T,'help',nM);R.az(EWEB.T.body,'dragend',va);R.az(EWEB.T,'keydown',sZ);R.az(EWEB.T,'keyup',sU);R.az(EWEB.T,'contextmenu',Cv);R.az(EWEB.T,'mousedown',rU);R.az(EWEB.T,'mouseup',rV);R.az(EWEB.T,'mousemove',sr);if(F.as){if(config.FixWidth){R.az(EWEB.T.getElementById("eWebEditor_FixWidth_DIV"),'beforedeactivate',function(){C.Save();});}else{R.az(EWEB.T,'beforedeactivate',function(){C.Save();});}}break;case "VIEW":EWEB.T.designMode="off";EWEB.T.open();EWEB.T.write(pG(V));EWEB.T.close();R.az(EWEB.T,'help',nM);R.az(EWEB.T,'contextmenu',R.aw);break;}if(!ub){ap.Save();}};function getHTML(uK){var V;switch(EWEB.ae){case "CODE":V=EWEB.db.value;break;case "EDIT":dp.wj();if(config.FixWidth){V=EWEB.T.getElementById("eWebEditor_FixWidth_DIV").innerHTML;}else{V=EWEB.T.body.innerHTML;}V=aE.wV(V);break;case "VIEW":V=$("D_ContentEdit").value;break;case "TEXT":V=EWEB.db.value;V=fn(V);break;default:V=$("D_ContentEdit").value;break;}if(!uK){if((V.toLowerCase()=="<p>&nbsp;</p>")||(V.toLowerCase()=="<p></p>")||(V.toLowerCase()=="<br>")){V="";}}return V;};function appendHTML(V){if(ps()){return;}switch(EWEB.ae){case "EDIT":V=aE.jY(V);var dK;if(config.FixWidth){dK=EWEB.T.getElementById("eWebEditor_FixWidth_DIV");}else{EWEB.T.body;}dK.innerHTML+=V;break;case "CODE":case "TEXT":EWEB.db.value+=V;break;}};function openUploadDialog(cT,dF,pw,pN,qK,hA){var aG='i_upload.htm?type='+cT+'&mode='+dF+'&savepathfilename='+pw+'&savefilename='+pN+'&originalfilename='+qK;if(hA){aG+='&returnflag='+hA;}ec.OpenDialog(aG);};function Remove(){if(EWEB.hq=="INPUT"){var aO=EWEB.bs.form;if(aO){R.hf(aO,'submit',ie);R.hf(aO,'reset',iT);}}};function ed(){if(EWEB.ae=="EDIT"){return true;}ec.OpenDialog("prompt.htm?prompt="+lang["MsgOnlyInEditMode"]);return false;};function ps(){if(EWEB.ae=="VIEW"){ec.OpenDialog("prompt.htm?prompt="+lang["MsgCanotSetInViewMode"]);return true;}return false;};function hH(){if(F.as){return true;}ec.OpenDialog("prompt.htm?prompt="+lang["MsgOnlyForIE"]);return false;};function format(aN,fN){if(!ed()){return;}C.Restore();EWEB.aR.focus();EWEB.Focus();ap.Save();if((aN=="unselect")&&(!F.as)){C.Collapse(true);}else if((aN=="selectall")&&(config.FixWidth)){pk();}else{EWEB.T.execCommand(aN,false,fN);}ap.Save();EWEB.Focus();ci.eW();};function pk(){var CI=EWEB.T.getElementById("eWebEditor_FixWidth_DIV");if(F.as){var r=EWEB.T.body.createTextRange();r.moveToElementText(CI);r.select();}else{var s=C.bG();var r=EWEB.T.createRange();r.selectNodeContents(CI);s.removeAllRanges();s.addRange(r);}};function nq(s){var r;switch(s+""){case "1":r="8pt";break;case "2":r="10pt";break;case "3":r="12pt";break;case "4":r="14pt";break;case "5":r="18pt";break;case "6":r="24pt";break;case "7":r="36pt";break;default:r="";break;}return r;};function setMode(dA,ud){if(dA==EWEB.ae){return;}if(dA=="TEXT"){if(EWEB.ae==$("D_CurrMode").value){if(!confirm(lang["MsgHtmlToText"])){return;}}}try{$("eWebEditor_CODE").className="SB_Mode_BtnOff";}catch(e){}try{$("eWebEditor_EDIT").className="SB_Mode_BtnOff";}catch(e){}try{$("eWebEditor_TEXT").className="SB_Mode_BtnOff";}catch(e){}try{$("eWebEditor_VIEW").className="SB_Mode_BtnOff";}catch(e){}try{$("eWebEditor_"+dA).className="SB_Mode_BtnOn";}catch(e){}var ja=$("eWebEditor_ToolarTREdit");var hQ=$("eWebEditor_ToolarTRText");if(EWEB.ReadOnly){ja.style.display="none";hQ.style.display="none";}else{if(dA=="EDIT"){ja.style.display="";hQ.style.display="none";}else{ja.style.display="none";if(config.TB2Flag=="1"){hQ.style.display="";}else{hQ.style.display="none";}}}if(dA=="EDIT"||dA=="VIEW"){$("eWebEditor").style.display="";$("eWebEditorTextarea").style.display="none";}else{$("eWebEditor").style.display="none";$("eWebEditorTextarea").style.display="";if(dA=="CODE"){$("eWebEditorTextarea").className="codemode";}else{$("eWebEditorTextarea").className="textmode";}}var V=getHTML(true);EWEB.ae=dA;$("D_CurrMode").value=dA;setHTML(V);if(dA=="EDIT"){jK.jJ();kh.jJ();}ci.rk();if(!ud){EWEB.Focus();}};function kZ(el){var sl=["p","div","h1","h2","h3","h4","h5","h6","pre","ol","ul","pre","fieldset","form","table","blockquote","dl","li","br"];var rW=["script","style","table","object","embed"];var bE="";var de=el.childNodes;for(var i=0;i<de.length;i++){if(de[i].nodeType==1){var aH=de[i].tagName.toLowerCase();if(rW.IndexOf(aH)<0){if(aH=="pre"){var lg=de[i].innerHTML;lg=lg.replace(/<[^>]*?>/gi,"");bE+=lg;}else{bE+=kZ(de[i]);}}if(sl.IndexOf(aH)>=0){bE+="\n";}}else if(de[i].nodeType==3){bE+=de[i].nodeValue;}}return bE;};function aK(aG,uE,tn,fP){if(uE&& !ed()){return;}if(tn&& !hH()){return;}if(aG.indexOf(".")<0){aG=aG+".htm";}ap.Save();ec.OpenDialog(aG,fP);};function fn(V){if(V==null){return "";}V=V.replace(/&/gi,"&amp;");V=V.replace(/\"/gi,"&quot;");V=V.replace(/</gi,"&lt;");V=V.replace(/>/gi,"&gt;");V=V.replace(/ (?= )/gi,"&nbsp;");V=V.replace(/\n/gi,"<br>");return V;};function uf(V){if(V==null){return "";}V=V.replace(/<br(?=[ \/>]).*?>/gi,"\n");V=V.replace(/&nbsp;;/gi," ");V=V.replace(/&quot;/gi,"\"");V=V.replace(/&lt;/gi,"<");V=V.replace(/&gt;/gi,">");V=V.replace(/&amp;/gi,"&");return V;};function addUploadFile(cf,fo){var qN=fo.substr(fo.lastIndexOf("/")+1);hY(aA.wg,cf);hY(aA.vZ,qN);hY(aA.vj,fo);};function hY(gn,bv){if(bv==""){return;}if(gn){var cK=parent.document.getElementById(gn);if(!cK){cK=parent.document.getElementsByName(gn)[0];}if(cK){if(cK.value!=""){cK.value=cK.value+"|";}cK.value=cK.value+bv;try{cK.onchange();}catch(e){}}}};function pb(hv,V){hv.value=V;if(config.ServerExt!="asp"){return;}var ny=hv.name;var aO=hv.form;var mU=R.dV(hv);var ga=50000;var K=mU.getElementsByName(ny);for(var i=1;i<K.length;i++){K[i].value="";}if(V.length>ga){hv.value=V.substr(0,ga);V=V.substr(ga);while(V.length>0){var fV;if(F.as){fV=mU.createElement('<textarea name="'+ny+'"></textarea>');}else{fV=mU.createElement("textarea");fV.setAttribute("name",ny);}fV.style.display="none";fV.value=V.substr(0,ga);aO.appendChild(fV);V=V.substr(ga);}}};function remoteUploadOK(){$("divProcessing").style.display="none";if(EWEB.bs){if(ld){eval("parent."+ld);}}};var ld;function remoteUpload(pO){if(config.AutoRemote!="1"){return;}if(EWEB.ae=="TEXT"){return;}ld=pO;var xc=document.getElementsByName("eWebEditor_UploadText")[0];pb(xc,getHTML());nz(lang["MsgRemoteUploading"]);$("eWebEditor_UploadForm").submit();};function localUpload(){if(!hH()){return;}if(EWEB.ae=="TEXT"){return;}if(!eY(true)){return;}nz(lang["MsgLocalUploading"]);var fh=getHTML();aZ.LocalUpload(fh);window.setTimeout("od()",100);};function od(){if(aZ.Status!="ok"){window.setTimeout("od()",100);return;}if(es()){$("divProcessing").style.display="none";return;}var ek=aZ.OriginalFiles;var gw=aZ.SavedFiles;if(ek){var ea=ek.split("|");var ey=gw.split("|");for(var i=0;i<ea.length;i++){if(ey[i]){var cf=ea[i];var fo=ey[i];addUploadFile(cf,fo);}}}var fh=aZ.Body;setHTML(fh,true);aZ=null;$("divProcessing").style.display="none";};function nz(msg){$("msgProcessing").innerHTML=msg;$("divProcessing").style.top=(document.body.clientHeight-parseFloat($("divProcessing").style.height))/2;$("divProcessing").style.left=(document.body.clientWidth-parseFloat($("divProcessing").style.width))/2;$("divProcessing").style.display="";};function pG(V){var dS;if(F.nb){dS='<!DOCTYPE html>';}else{dS='<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">';}dS+='<html><head>';dS+='<link href="'+EWEB.cd+'/skin/'+config.Skin+'/editarea.css" type="text/css" rel="stylesheet">';if(config.AreaCssMode!='1'){dS+='<link href="'+EWEB.cd+'/language/'+lang.bF+'.editarea.css" type="text/css" rel="stylesheet">';}switch(EWEB.ae){case 'CODE':break;case 'TEXT':break;case 'EDIT':case 'VIEW':if(config.AreaCssMode!='1'){dS+='<link href="'+EWEB.cd+'/skin/'+config.Skin+'/editarea.'+lang.bF+'.css" type="text/css" rel="stylesheet">';}dS+=EWEB.ExtCSS;break;}if(EWEB.ae=="VIEW"){dS+='<base target="_blank">';V=V.replace(/(<a\s[^>]*?target\s*?=\s*?[\'\"]?)\_[a-zA-Z]+([\'\"]?[^>]*?>)/gi,'$1_blank$2');}dS+=EWEB.BaseHref+'</head>';var aI=dS;if(config.FixWidth){aI+='<body class="ewebeditor__fixwidth">'+'<div id="eWebEditor_FixWidth_DIV" style="width:'+config.FixWidth+';" >';if(!F.as&&V==''){aI+='<br>';}aI+=V+'</div></body>';}else{aI+='<body>'+V+'</body>';}return aI;};function getCount(jN){var bM=getText();bM=bM.replace(/\n/g,"");bM=bM.replace(/\r/g,"");var l=bM.length;var n=0;for(var i=0;i<l;i++){if(bM.charCodeAt(i)<0||bM.charCodeAt(i)>255){if(jN!=0){n++;if(jN==3){n++;}}}else{if(jN!=1){n++;}}}return n;};function getText(){var bE;if(EWEB.ae=="TEXT"){bE=EWEB.db.value;}else{$("eWebEditor_Temp_HTML").innerHTML=getHTML();if(F.as){bE=$("eWebEditor_Temp_HTML").innerText;}else{bE=kZ($("eWebEditor_Temp_HTML"));}}return bE;};function ng(url){document.write('<scr'+'ipt type="text/javascript" src="'+url+'" onerror="alert(\'Error loading \' + this.src);"><\/scr'+'ipt>');};function wr(){if(!config.L){document.write("<table style='width:100%;height:100%;border-collapse:collapse' borderColor='#999999' bgColor='#ffffff' border='1px'><tr><td align='center' style='font-size:9pt'>eWebEditor!<br><br>"+lang["ErrLicense"]+"</td></tr></table>");return;}var bC="";bC+="<table id='eWebEditor_Layout' border='0' cellpadding='0' cellspacing='0' width='100%' height='100%' style='table-layout:fixed'>";bC+="<tr id='eWebEditor_ToolarPTR'><td>";bC+="<table id='eWebEditor_Toolbar' border=0 cellpadding=0 cellspacing=0 width='100%'>";bC+="<tr id='eWebEditor_ToolarTRText' style='display:none'><td>";bC+=qy(vL(),"Text");bC+="</td></tr>";bC+="<tr id='eWebEditor_ToolarTREdit' style='display:'><td>";bC+=qy(config.Toolbars,"Edit");bC+="</td></tr>";bC+="</table>";bC+="</td></tr>";bC+="<tr><td id='eWebEditor_EditareaTD' height='100%'>";bC+="<input type='hidden' id='D_ContentEdit' value=''>";bC+="<input type='hidden' id='D_CurrMode' value=''>";bC+="<input type='hidden' id='D_ContentLoad' value=''>";bC+="<input type='hidden' id='D_ContentFlag' value='0'>";bC+="<input type='hidden' id='D_PaginationTitle' value=''>";bC+="<textarea id='eWebEditorTextarea' style='display:none;width:100%;height:100%;'></textarea>";bC+='<iframe id="eWebEditor" width="100%" height="100%" scrolling="yes" frameborder="0" src="'+R.iO()+'"></iframe>';bC+="</td></tr>";if(config.StateFlag){bC+="<tr id='eWebEditor_SB'><td class='SB'>";bC+="	<table border='0' cellpadding='0' cellspacing='0' width='100%' class='SB'>";bC+="	<tr valign='middle'>";bC+="	<td>";bC+="		<table id='eWebEditor_SB_Mode' border='0' cellpadding='0' cellspacing='0' class='SB_Mode'>";bC+="		<tr>";bC+="		<td class='SB_Mode_Left'></td>";if(config.SBCode){bC+="		<td class=SB_Mode_BtnOff id=eWebEditor_CODE onclick=\"setMode('CODE')\" unselectable=on><table border=0 cellpadding=0 cellspacing=0><tr><td class=SB_Mode_Btn_Img>"+ef("ModeCode")+"</td><td class=SB_Mode_Btn_Text>"+lang["StatusModeCode"]+"</td></tr></table></td>";bC+="		<td class=SB_Mode_Sep></td>";}if(config.SBEdit){bC+="		<td class=SB_Mode_BtnOff id=eWebEditor_EDIT onclick=\"setMode('EDIT')\" unselectable=on><table border=0 cellpadding=0 cellspacing=0><tr><td class=SB_Mode_Btn_Img>"+ef("ModeEdit")+"</td><td class=SB_Mode_Btn_Text>"+lang["StatusModeEdit"]+"</td></tr></table></td>";bC+="		<td class=SB_Mode_Sep></td>";}if(config.SBText){bC+="		<td class=SB_Mode_BtnOff id=eWebEditor_TEXT onclick=\"setMode('TEXT')\" unselectable=on><table border=0 cellpadding=0 cellspacing=0><tr><td class=SB_Mode_Btn_Img>"+ef("ModeText")+"</td><td class=SB_Mode_Btn_Text>"+lang["StatusModeText"]+"</td></tr></table></td>";bC+="		<td class=SB_Mode_Sep></td>";}if(config.SBView){bC+="		<td class=SB_Mode_BtnOff id=eWebEditor_VIEW onclick=\"setMode('VIEW')\" unselectable=on><table border=0 cellpadding=0 cellspacing=0><tr><td class=SB_Mode_Btn_Img>"+ef("ModeView")+"</td><td class=SB_Mode_Btn_Text>"+lang["StatusModeView"]+"</td></tr></table></td>";}bC+="		</tr>";bC+="		</table>";bC+="	</td>";if(aA.FullScreen!="1"&&config.SBSize){bC+="	<td align=right>";bC+="		<table id='eWebEditor_SB_Size' border=0 cellpadding=0 cellspacing=0 class=SB_Size>";bC+="		<tr>";bC+="		<td class=SB_Size_Btn onclick='ej(300)' title='"+lang["SizePlus"]+"'>"+ef("SizePlus")+"</td>";bC+="		<td class=SB_Size_Sep></td>";bC+="		<td class=SB_Size_Btn onclick='ej(-300)' title='"+lang["SizeMinus"]+"'>"+ef("SizeMinus")+"</td>";bC+="		<td class=SB_Size_Right></td>";bC+="		</tr>";bC+="		</table>";bC+="	</td>";}bC+="	</tr>";bC+="	</Table>";bC+="</td></tr>";}bC+="</table>";bC+="<div id='eWebEditor_Temp_HTML' style='visibility:hidden;overflow:hidden;position:absolute;width:1px;height:1px'></div>";bC+="<div style='position:absolute;display:none'>";bC+="<form id='eWebEditor_UploadForm' action='"+config.ServerExt+"/upload."+config.ServerExt+"?action=remote&type=remote&style="+aA.StyleName+"&language="+lang.bF+"&cusdir="+aA.CusDir+"&skey="+aA.SKey+"' method='post' target='eWebEditor_UploadTarget'>";bC+="<input type='hidden' name='eWebEditor_UploadText'>";bC+="</form>";bC+='<iframe name="eWebEditor_UploadTarget" width=0 height=0 src="'+R.iO()+'"></iframe>';bC+="</div>";bC+="<div id=divProcessing style='width:200px;height:30px;position:absolute;display:none'>";bC+="<table border=0 cellpadding=0 cellspacing=1 bgcolor='#000000' width='100%' height='100%'><tr><td bgcolor=#3A6EA5><marquee id='msgProcessing' align='middle' behavior='alternate' scrollamount='5' style='font-size:9pt;color:#ffffff'></marquee></td></tr></table>";bC+="</div>";bC+="<div id='div_TableResizeSepV' style='position:absolute;display:none;background-color:transparent;overflow:hidden;' onmousedown='cW.MD2(event)' onmousemove='cW.MM2(event)' onmouseup='cW.MU2(event)'></div>";bC+="<div id='div_TableResizeSepH' style='position:absolute;display:none;background-color:transparent;overflow:hidden;' onmousedown='cW.MD2(event)' onmousemove='cW.MM2(event)' onmouseup='cW.MU2(event)'></div>";document.write(bC);};function qy(qH,sB){var aI="<table border='0' cellpadding='0' cellspacing='0' width='100%' id='eWebEditor_Toolbar_"+sB+"' unselectable>";for(var i=0;i<qH.length;i++){aI+="<tr><td class='TB_Left'></td><td class='TB_Center'><table border='0' cellpadding='0' cellspacing='0'><tr>";var tb=qH[i];for(var j=0;j<tb.length;j++){var aM=tb[j];var di=Buttons[aM];var hL=di[1]?di[1]:"exec('"+aM+"')";if(aM=="TBSep"){aI+="<td class='TB_Btn_Padding'><div class='TB_Sep'></div></td>";}else if(di[3]==0){aI+="<td class='TB_Btn_Padding'><div class='TB_Btn' name='TB_Name_"+aM+"' title=\""+lang[aM]+"\" onclick=\""+hL+"\">";if(typeof(di[0])=="number"){var cA="skin/"+config.Skin+"/buttons.gif";var dM=16-di[0]*16;if(F.as){aI+="<div class='TB_Btn_Image'><img src='"+cA+"' style='top:"+dM+"px' /></div>";}else{aI+="<img class='TB_Btn_Image' src='sysimage/space.gif' style='background-position: 0px "+dM+"px;background-image: url("+cA+");' />";}}else{var cA="skin/"+config.Skin+"/"+di[0];aI+="<img class='TB_Btn_Image' src='"+cA+"'>";}aI+="</div></td>";}else if(di[3]==1){var fS="";var bW="";switch(aM){case "FontName":fS=" style='width:115px'";for(var k=0;k<lang[aM+"Item"].length;k++){bW+="<option value='"+lang[aM+"Item"][k]+"'>"+lang[aM+"Item"][k]+"</option>";}break;case "FontSize":fS=" style='width:55px'";for(var k=0;k<lang[aM+"Item"].length;k++){bW+="<option value='"+lang[aM+"Item"][k][0]+"'>"+lang[aM+"Item"][k][1]+"</option>";}break;case "FormatBlock":fS=" style='width:90px'";for(var k=0;k<lang[aM+"Item"].length;k++){bW+="<option value='"+lang[aM+"Item"][k][0]+"'>"+lang[aM+"Item"][k][1]+"</option>";}break;case "ZoomSelect":fS=" style='width:55px'";for(var k=0;k<cY.Options.length;k++){bW+="<option value='"+cY.Options[k]+"'>"+cY.Options[k]+"%</option>";}break;}aI+="<td class='TB_Btn_Padding'><select name='TB_Name_"+aM+"' onchange=\""+hL+"\" size=1 "+fS+"><option selected>"+lang[aM]+"</option>"+bW+"</select></td>";}}aI+="</tr></table></td><td class='TB_Right'></td></tr>";}aI+="</table>";return aI;};function vL(){var a=new Array();var b=false;a.push("TBHandle");if(config.TB2Mode=="1"){a.push("ModeCode");a.push("ModeEdit");a.push("ModeText");a.push("ModeView");b=true;}if(config.TB2Max=="1"){if(b){a.push("TBSep");}a.push("Maximize");}return[a];};function ef(aM,rg){var cp=Buttons[aM];var dM=16-cp[0]*16;var cA="skin/"+config.Skin+"/buttons.gif";if(F.as){return "<div><img src='"+cA+"' style='top:"+dM+"px'></div>";}else{return "<img class='SB_Btn_Image' src='sysimage/space.gif' style='background-position: 0px "+dM+"px;background-image: url("+cA+");' />";}};var dp=new Object();dp.fv=function(){if(config.PaginationMode=="0"){return false;}EWEB.Focus();var el;if(C.ai()=="Control"){el=C.ax();}else{el=C.cI();}el=this.oS(el);if(!el){insertHTML("</P><P id=eWebEditor_Temp_P>");var p=EWEB.T.getElementById("eWebEditor_Temp_P");p.removeAttribute("id");this.ez(p,"beforeBegin");}else{this.ez(el,"afterEnd");}};dp.ez=function(el,kH){var oI=false;if(kH=="afterEnd"&&(!el.nextSibling)){oI=true;}var aU=EWEB.T.createElement("img");aU.className="ewebeditor__pagination";aU.setAttribute("_ewebeditor_fake_tag","pagination");aU.setAttribute("src",EWEB.cd+"/sysimage/space.gif");if(F.as){el.insertAdjacentElement(kH,aU);}else{if(kH=="beforeBegin"){el.parentNode.insertBefore(aU,el);}else{el.parentNode.insertBefore(aU,el.nextSibling);}}if(oI){var p=EWEB.T.createElement("p");el.parentElement.appendChild(p);}};dp.oS=function(el){if(el.tagName=="HTML"){return null;}var te=null;if(config.FixWidth){while(!((el.tagName.toUpperCase()=="DIV")&&(el.getAttribute("id")=="eWebEditor_FixWidth_DIV"))){te=el;el=el.parentNode;if(!el|| !el.tagName){break;}}}else{while(el.tagName.toUpperCase()!="BODY"){te=el;el=el.parentNode;if(!el|| !el.tagName){break;}}}return te;};dp.Auto=function(qC){if(config.PaginationMode=="0"){return false;}this.Empty();var lh=parseInt(qC);if(lh<1){return false;}if(getCount(2)<=lh){return false;}if(EWEB.ae!="EDIT"){setMode("EDIT");}var dK;if(config.FixWidth){dK=EWEB.T.getElementById("eWebEditor_FixWidth_DIV");}else{dK=EWEB.T.body;}var de=dK.childNodes;var l=0;for(var i=0;i<de.length;i++){var bz=de[i];if(bz.nodeType==1){var s=bz.innerText||bz.textContent;if(s){l+=s.length;}}else if(bz.nodeType==3){l+=bz.length;}if(l>=lh){if(bz.nextSibling){if(bz.nodeType==1){this.ez(bz,"afterEnd");}else{this.ez(bz.nextSibling,"beforeBegin");}l=0;}}}};dp.Empty=function(){if(config.PaginationMode=="0"){return;}var K=EWEB.T.getElementsByTagName("IMG");for(var i=K.length-1;i>=0;i--){var el=K[i];var cb=el.getAttribute("_ewebeditor_fake_tag",2);if(cb){if(cb.toLowerCase()=="pagination"){R.cE(el);}}}};dp.wj=function(){if(config.PaginationMode=="0"){return false;}var K=EWEB.T.getElementsByTagName("IMG");for(var i=K.length-1;i>=0;i--){var el=K[i];var cb=el.getAttribute("_ewebeditor_fake_tag",2);if(cb){if(cb.toLowerCase()=="pagination"){var te=this.oS(el);if(te){var b=false;if(te.tagName=="DIV"||te.tagName=="P"){var s=te.innerText||te.textContent;s=s.oz();if(!s){b=true;this.ez(te,"beforeBegin");R.cE(te);}}if(!b){this.ez(te,"afterEnd");R.cE(el);}}}}}};var aE=new Object();aE.jY=function(V){V=this.rZ(V);V=this.ob(V,'script',/<script[\s\S]*?<\/script>/gi);V=this.ob(V,'noscript',/<noscript[\s\S]*?<\/noscript>/gi); V=this.sI(V);V=this.uU(V);V=this.sX(V);V=this.pa(V,"img","src");V=this.pa(V,"a","href");V=this.pa(V,"area","href");return V;};aE.wV=function(V){V=this.rG(V);V=this.sQ(V);V=this.sO(V);V=this.vb(V);V=this.sG(V);return V;};aE.wv=function(){var el=C.ax();return el.getAttribute("_ewebeditor_fake_tag",2);};aE.ob=function(V,aH,um){function _Replace(m){return aE.ct(aH,m);};return V.replace(um,_Replace);};aE.vb=function(V){function _Replace(m,aH){function gm(m,bv){if(['flash','flv','mediaplayer6','mediaplayer7','realplayer','quicktime','unknownobject'].IndexOf(aH)>=0){var ak=aE.pr(m,'img');if(ak!=''){ak=' style='+ak;}var eh=(aE.mA(m,'img','width')=='')?aE.co(m,'img','width'):'';var ff=(aE.mA(m,'img','height')=='')?aE.co(m,'img','height'):'';var fQ=aE.co(m,'img','align');var jB=aE.co(m,'img','vspace');var gq=aE.co(m,'img','hspace');var eu=decodeURIComponent(bv);eu=aE.ov(eu,"object",ak);eu=aE.ov(eu,"embed",ak);eu=aE.sv(eu,["object","embed"],[["width",eh],["height",ff],["align",fQ],["vspace",jB],["hspace",gq]]);return eu;}else{return decodeURIComponent(bv);}};return m.replace(/<img [^>]*?_ewebeditor_fake_value=\"([^\">]+?)\"[^>]*?>/gi,gm);};return V.replace(/<img [^>]*?_ewebeditor_fake_tag=\"(\w+?)\"[^>]*?>/gi,_Replace);};aE.rZ=function(V){if(config.PaginationMode=="0"){return V;}var aI='';var fg='';var cA=aE.ct('pagination',"");if(config.PaginationMode=="1"){aI="";var re=/<!--ewebeditor:page title=\"([^\">]*)\"-->((?:[^a]|a)+?)<!--\/ewebeditor:page-->/gi;var m;var ir=0;while((m=re.exec(V))!=null){ir++;fg+=uf(m[1])+"\r\n";if(aI!=""){aI+=cA;}aI+=m[2];}if(ir==0){aI=V;}}else{var re=new RegExp(config.PaginationKey.replace(/([\[\]\{\}\.\(\)\*\+\?])/gi,"\\$1"),'gi');aI=V.replace(re,cA);}$("D_PaginationTitle").value=fg;return aI;};aE.rG=function(V){if(config.PaginationMode=="0"){return V;}var aI=V;var a=V.split(/<img [^>]*?_ewebeditor_fake_tag=\"pagination\"[^>]*?>/gi);if(a.length>1){if(config.PaginationMode=="1"){aI="";var iv=$("D_PaginationTitle").value.split("\r\n");for(var i=0;i<a.length;i++){var fg="";if(iv[i]){fg=fn(iv[i]);}aI+="<!--ewebeditor:page title=\""+fg+"\"-->\r\n";aI+=a[i]+"\r\n";aI+="<!--/ewebeditor:page-->\r\n\r\n";}}else{aI=a[0];for(var i=1;i<a.length;i++){aI+="\r\n"+config.PaginationKey+"\r\n"+a[i];}}}return aI;};aE.sI=function(V){function _Replace(m){var dG=m.replace(/<object [^>]*?classid\s*=\s*[\'\"]?clsid\s*:\s*([a-z0-9\-]+)[\'\"]?[^>]*?>[\s\S]*/gi,'$1');dG=dG.toUpperCase();if(dG=='D27CDB6E-AE6D-11CF-96B8-444553540000'){if(/plugin\/flvplayer\.swf/.test(m)&&/flashvars[^>]*?\.flv/.test(m)){return aE.ct('flv',m,'object');}else{return aE.ct('flash',m,'object');}}else if(dG=='22D6F312-B0F6-11D0-94AB-0080C74C7E95'){return aE.ct('mediaplayer6',m,'object');}else if(dG=='6BF52A52-394A-11D3-B153-00C04F79FAA6'){return aE.ct('mediaplayer7',m,'object');}else if(dG=='CFCDAA03-8BE4-11CF-B84B-0020AFBBCCFA'){return aE.ct('realplayer',m,'object');}else if(dG=='02BF25D5-8C17-4B23-BC80-D3488ABDDC6B'){return aE.ct('quicktime',m,'object');}else if(dG=='0002E510-0000-0000-C000-000000000046'||dG=='0002E551-0000-0000-C000-000000000046'||dG=='0002E559-0000-0000-C000-000000000046'){return m;}else{return aE.ct('unknownobject',m,'object');}};return V.replace(/<object[\s\S]*?<\/object>/gi,_Replace);};aE.uU=function(V){function _Replace(m){var cT=m.replace(/<embed [^>]*?type\s*=\s*[\'\"]?([^\'\"\s]+)[\'\"]?[^>]*?>[\s\S]*/gi,'$1');cT=cT.toLowerCase();if(cT=='application/x-shockwave-flash'){return aE.ct('flash',m,'embed');}else if(['application/x-mplayer2','video/x-ms-asf','video/x-msvideo','video/mpeg','audio/mid','audio/mpeg','audio/wav','video/x-ms-wm','audio/x-ms-wma','video/x-ms-wmv','video/x-ms-wmp','video/x-ms-wmx'].IndexOf(cT)>=0){return aE.ct('mediaplayer6',m,'embed');}else if(cT=='video/quicktime'){return aE.ct('quicktime',m,'embed');}else if(['audio/x-pn-realaudio','audio/x-pn-realaudio-plugin','application/vnd.rn-realmedia'].IndexOf(cT)>=0){return aE.ct('realplayer',m,'embed');}else{return aE.ct('unknownobject',m,'embed');}};return V.replace(/<embed[\s\S]*?<\/embed>/gi,_Replace);};aE.ct=function(aH,bv,eJ){if(eJ){var ak=aE.pr(bv,eJ);var eh=aE.co(bv,eJ,'width');var ff=aE.co(bv,eJ,'height');var fQ=aE.co(bv,eJ,'align');var jB=aE.co(bv,eJ,'vspace');var gq=aE.co(bv,eJ,'hspace');if(ak!=''){ak=' style='+ak;}var V='<img src="'+EWEB.cd+'/sysimage/space.gif" class="ewebeditor__'+aH+'" _ewebeditor_fake_tag="'+aH+'" _ewebeditor_fake_value="'+encodeURIComponent(bv)+'"'+ak;if(eh!=''){V+=' width="'+eh+'"';}if(ff!=''){V+=' height="'+ff+'"';}if(fQ!=''){V+=' align="'+fQ+'"';}if(jB!=''){V+=' vspace="'+jB+'"';}if(gq!=''){V+=' hspace="'+gq+'"';}V+='>';return V;}else{return '<img src="'+EWEB.cd+'/sysimage/space.gif" class="ewebeditor__'+aH+'" _ewebeditor_fake_tag="'+aH+'" _ewebeditor_fake_value="'+encodeURIComponent(bv)+'">';}};aE.pr=function(V,aH){var re=new RegExp('^[\\s\\S]*?<'+aH+'(?=[\\s>])[^>]*?\\sstyle\\s*?=\\s*?(\'[^\'>]+?\'|\"[^\">]+?\")[^>]*?>[\\s\\S]*$','gi');if(re.test(V)){return V.replace(re,'$1');}else{return '';}};aE.mA=function(V,aH,bL){var re=new RegExp('^[\\s\\S]*?<'+aH+'(?=[\\s>])[^>]*?\\sstyle\\s*?=\\s*?([\'\"])[^>]*?\\b'+bL+'\\s*?:\\s*?(\\w+)(?=[\\s\;\'\"])[^>]*?\\1[^>]*?>[\\s\\S]*$','gi');if(re.test(V)){return V.replace(re,'$2');}else{return '';}};aE.co=function(V,aH,bL){var re=new RegExp('^[\\s\\S]*?<'+aH+'(?=[\\s>])[^>]*?\\s'+bL+'\\s*?=\\s*?([\'\"]?)(\\w+)\\1[^>]*?>[\\s\\S]*$','gi');if(re.test(V)){return V.replace(re,'$2');}else{return '';}};aE.ov=function(V,aH,ak){function _Replace(m){var r=/\sstyle\s*?=\s*?([\'\"])[^>]*?\1/gi;if(r.test(m)){ak=ak.replace('$','\\$');return m.replace(r,ak);}else{return m.substring(0,m.length-1)+ak+'>';}};var re=new RegExp('<'+aH+'(?=[\\s>])[^>]*?>','gi');return V.replace(re,_Replace);};aE.sv=function(V,eE,gc){for(var i=0;i<eE.length;i++){V=this.ti(V,eE[i],gc);}return V;};aE.ti=function(V,aH,gc){function _Replace(m){var bL,fO;for(var i=0;i<gc.length;i++){bL=gc[i][0];fO=gc[i][1];var s='';if(fO!=''){s=' '+bL+'="'+fO+'"';}var r=new RegExp('\\s'+bL+'\\s*?=\\s*?([\'\"]?)\\w+\\1','gi');if(r.test(m)){m=m.replace(r,s);}else{if(fO!=''){m=m.substring(0,m.length-1)+s+'>';}}}return m;};var re=new RegExp('<'+aH+'[^>]*?>','gi');return V.replace(re,_Replace);};aE.sX=function(V){function _Replace(m){function gC(m,bL){return ' _ewebeditor_pa_'+bL+'="'+encodeURIComponent(m)+'"';};return m.replace(/\s(on\w+)\s*=\s*?(\'|\")([\s\S]*?)\2/gi,gC);};return V.replace(/<[^\>]+ on\w+\s*=\s*?(\'|\")[\s\S]+?\>/gi,_Replace);};aE.sQ=function(V){function _Replace(m,m1){return decodeURIComponent(m1);};return V.replace(/\s_ewebeditor_pa_\w+=\"([^\"]+)\"/gi,_Replace);};aE.pa=function(V,aH,bL){function _Replace(m,m1,m2,m3,m4,m5){if(/_ewebeditor_ta_/.test(m)||/_ewebeditor_fake_/.test(m)){return m;}else{return m1+m2+' _ewebeditor_ta_'+bL+'="'+encodeURIComponent(m4.replace(/\"/gi,"'"))+'"'+m5;}};var re=new RegExp('(<'+aH+'(?=\\s)[^>]*?)(\\s'+bL+'\\s*?=\\s*?([\'\"])([^>]*?)\\3)([\\s\\S]*?>)','gi');return V.replace(re,_Replace);};aE.sO=function(V){function _Replace(m,bL,bv){var r=new RegExp('\\s'+bL+'\\s*?=\\s*?([\'\"])[^>]*?\\1','gi');var s=m.replace(r,'');r=new RegExp('\\s_ewebeditor_ta_'+bL+'+\\s*?=\\s*?\"[^\"]*?\"','gi');return s.replace(r,' '+bL+'="'+decodeURIComponent(bv)+'"');};return V.replace(/<\w+[^>]*?_ewebeditor_ta_(\w+)\s*?=\s*?\"([^\">]*?)\"[^>]*>/gi,_Replace);};aE.sG=function(V){V=V.replace(/(<\w+(?=\s)[^>]*?\sclass\s*?=[^>]*?)(ewebeditor__\w+)([^>]*?>)/gi,'$1$3');V=V.replace(/(<\w+(?=\s)[^>]*?)(\sclass\s*?=\s*?\"\s*\")([^>]*>)/gi,'$1$3');return V;};var vy={vi:function(V){var ka=this.tm();if(ka==''){return V;}var fa=this.uI(V);var kY=new Array();var qL=/^\<\/(HTML|HEAD|BODY|FORM|TABLE|TBODY|THEAD|TR|UL|OL|DL)[ \>]/i;var qk=/^\<(HTML|HEAD|BODY|FORM|TABLE|TBODY|THEAD|TR|UL|OL|DL)[ \/\>]/i;var pu=new RegExp('^'+ka);var gm=function(m,m1,m2,m3,m4){kY.push(m3);return m1+fa+m4;};var re=/(<(style|script|pre)(?=[\s>])[^>]*?>)([\s\S]*?)(<\/\2>)/gi;V=V.replace(re,gm);V=V.replace(/\<(P|DIV|H1|H2|H3|H4|H5|H6|ADDRESS|PRE|OL|UL|LI|DL|DT|DD|TITLE|META|LINK|BASE|SCRIPT|LINK|TD|TH|AREA|OPTION)[^\>]*\>/gi,'\n$&');V=V.replace(/\<\/(P|DIV|H1|H2|H3|H4|H5|H6|ADDRESS|PRE|OL|UL|LI|DL|DT|DD|TITLE|META|LINK|BASE|SCRIPT|LINK|TD|TH|AREA|OPTION)[^\>]*\>/gi,'$&\n');V=V.replace(/\<(BR|HR)[^\>]*\>/gi,'$&\n');V=V.replace(/\<\/?(HTML|HEAD|BODY|FORM|TABLE|TBODY|THEAD|TR)[^\>]*\>/gi,'\n$&\n');var nA=V.split(/\s*\n+\s*/g);var hE='';V='';for(var i=0;i<nA.length;i++){var gY=nA[i];if(gY.length==0){continue;}if(qL.test(gY)){hE=hE.replace(pu,'');}V+=hE+gY+'\n';if(qk.test(gY)){hE+=ka;}}var gC=function(m,m1,m2){return m1.toLowerCase()+m2;};V=V.replace(/(<\/?\w+(?=[\s>]))([^>]*?>)/gi,gC);var nI=V.split(fa);V=nI[0];for(var i=0;i<kY.length;i++){V+=kY[i]+nI[i+1];}return V.oz();},uI:function(V){var fa='__ewebeditor__sepstr__';var i=0;while(true){i=i+1;fa=fa+i;if(V.indexOf(fa)<0){break;}}return fa;},tm:function(){var n=parseInt(config.CodeFormat);var oB='';for(var i=0;i<n;i++){oB+=' ';}return oB;}};function ej(lW){for(var i=0;i<parent.frames.length;i++){try{if(parent.frames[i].document==self.document){var bQ=parent.frames[i].frameElement;var cq=parseInt(bQ.offsetHeight);if(cq+lW>=config.UIMinHeight){bQ.height=cq+lW;}else{bQ.height=config.UIMinHeight;}break;}}catch(e){}}};function qG(){var cR=EWEB.T.createElement("div");cR.innerHTML='<span style="margin:0;padding:0;border:0;clear:both;width:1px;height:1px;display:block;">'+(F.xb?'&nbsp;':'')+'</span>';var gi=R.cE(cR.firstChild);var dK;if(config.FixWidth){dK=EWEB.T.getElementById("eWebEditor_FixWidth_DIV");}else{dK=F.as?EWEB.T.body:EWEB.T.documentElement;}dK.appendChild(gi);var wN=R.hg(EWEB.aR,gi).y;if(!config.FixWidth){wN+=gi.offsetHeight;}R.cE(gi);var vA=R.eF(EWEB.aR).Height;var jR=wN-vA;if(F.jo){jR+=20;}if(Math.abs(jR)<3){return;}var mg=R.mD(document).frameElement;var wK=mg.offsetHeight;var vm=Math.max(wK+jR,parseInt(config.UIMinHeight));mg.height=vm;};function uT(){if(!hH()){return;}try{var sy=new ActiveXObject("ieSpell.ieSpellExtension");sy.xv(EWEB.T);}catch(yx){if(confirm(lang["MsgIeSpellDownload"])){window.open("http://www.iespell.com/download.php","IeSpellDownload");}}};function qu(){aK('findreplace.htm',true);};function tM(){if(!ed()){return;}EWEB.Focus();if(!iY()){ec.OpenDialog("prompt.htm?prompt="+lang["MsgNotParagraph"]);return;}aK('paragraph.htm',true);};function iY(){if(C.ai()=="Control"){return false;}if(F.as){var fH=EWEB.T.selection.createRange();var dK=EWEB.T.body;var hF=dK.getElementsByTagName("P");var eo=dK.createTextRange();for(var i=0;i<hF.length;i++){eo.moveToElementText(hF[i]);if(fH.inRange(eo)){return true;}else{if(((fH.compareEndPoints("StartToEnd",eo)<0)&&(fH.compareEndPoints("StartToStart",eo)>0))||((fH.compareEndPoints("EndToStart",eo)>0)&&(fH.compareEndPoints("EndToEnd",eo)<0))){return true;}}}}else{var fH=EWEB.aR.getSelection();var dK=EWEB.T.body;var hF=dK.getElementsByTagName("P");for(var i=0;i<hF.length;i++){if(fH.containsNode(hF[i],true)){return true;}}}return false;};function tQ(){if(!ed()){return;}ap.Save();var b=false;if(C.ai()=="Control"){var bg=C.ax();if(bg.tagName.toUpperCase()=="IMG"){b=true;}}if(!b){ec.OpenDialog("prompt.htm?prompt="+lang["MsgMapLimit"]);return;}aK("map.htm",true);};function uB(){if(!ed()){return;}if(C.ai()=="Control"){var bg=C.ax();if(bg.tagName.toUpperCase()!="IMG"){ec.OpenDialog("prompt.htm?prompt="+lang["MsgHylnkLimit"]);return;}}aK("hyperlink.htm",true);};function dB(aN){if(!ed()){return;}EWEB.Focus();ap.Save();var bE;if(F.as){var bk=EWEB.T.selection.createRange();bE=bk.text;}else{bE=EWEB.aR.getSelection().toString();}switch(aN){case "nowdate":var d=new Date();insertHTML(d.toLocaleDateString());break;case "nowtime":var d=new Date();insertHTML(d.toLocaleTimeString());break;case "br":insertHTML("<br>");break;case "code":insertHTML('<table width=95% border="0" align="Center" cellpadding="6" cellspacing="0" style="border: 1px Dotted #CCCCCC; TABLE-LAYOUT: fixed"><tr><td bgcolor=#FDFDDF style="WORD-WRAP: break-word"><font style="color: #990000;font-weight:bold">'+lang["HtmlCode"]+'</font><br>'+fn(bE)+'</td></tr></table>');break;case "quote":insertHTML('<table width=95% border="0" align="Center" cellpadding="6" cellspacing="0" style="border: 1px Dotted #CCCCCC; TABLE-LAYOUT: fixed"><tr><td bgcolor=#F3F3F3 style="WORD-WRAP: break-word"><font style="color: #990000;font-weight:bold">'+lang["HtmlQuote"]+'</font><br>'+fn(bE)+'</td></tr></table>');break;case "big":insertHTML("<big>"+bE+"</big>");break;case "small":insertHTML("<small>"+bE+"</small>");break;case "printbreak":insertHTML("<div style=\"FONT-SIZE: 1px; PAGE-BREAK-BEFORE: always; VERTICAL-ALIGN: middle; HEIGHT: 1px; BACKGROUND-COLOR: #c0c0c0\">&nbsp; </div>");break;default:ec.OpenDialog("prompt.htm?prompt="+lang["ErrParam"]);break;}};var cY={Options:[10,25,50,75,100,150,200,500],qr:100,Execute:function(kX){if(F.as){EWEB.T.body.runtimeStyle.zoom=kX+"%";}else{EWEB.T.body.style.MozTransform='scale('+(kX/100)+')';}this.qr=kX;}};function uD(){if(C.ai()!="Control"){return;}if(F.as){var fA=EWEB.T.selection.createRange();for(var i=0;i<fA.length;i++){var bg=fA.item(i);if(bg.style.position!='relative'){bg.style.position='relative';}else{bg.style.position='static';}}}else{var bg=C.ax();if(bg.style.position!='relative'){bg.style.position='relative';}else{bg.style.position='static';}}};function pe(an){if(C.ai()!="Control"){return;}if(F.as){var fA=EWEB.T.selection.createRange();for(var i=0;i<fA.length;i++){var bg=fA.item(i);if(an=='forward'){bg.style.zIndex+=1;}else{bg.style.zIndex-=1;}bg.style.position='relative';}}else{var bg=C.ax();if(an=='forward'){bg.style.zIndex+=1;}else{bg.style.zIndex-=1;}bg.style.position='relative';}};function pl(what){C.Restore();EWEB.aR.focus();if(C.ai()!="Text"){return;}ap.Save();if(F.as){var bk=EWEB.T.selection;var aD=bk.createRange();var r=EWEB.T.body.createTextRange();var ni=0;while(r.compareEndPoints("StartToStart",aD)<0){r.moveStart("character",1);ni++;}var eQ=0;while(r.compareEndPoints("EndToEnd",aD)>0){r.moveEnd("character",-1);eQ--;}var a=["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"];var l,u,gr,kK;for(var i=0;i<26;i++){l=a[i];u=a[i].toUpperCase();switch(what){case "uppercase":gr=l;kK=u;break;case "lowercase":gr=u;kK=l;break;}r=aD.duplicate();while(r.findText(gr,0,4)){r.text=kK;r=aD.duplicate();}}r=EWEB.T.body.createTextRange();r.moveStart("character",ni);r.moveEnd("character",eQ);r.select();}else{nL.og(what);}ap.Save();};function fq(aN,fN){C.Restore();EWEB.aR.focus();if(C.ai()!="Text"){return;}ap.Save();var pi="eWebEditor_Temp_FontName";if(F.as){EWEB.T.execCommand("fontname","",pi);var r=EWEB.T.selection.createRange();if(r.text==""){return;}var lm=EWEB.T.body.getElementsByTagName("FONT");var by=new Array();for(var i=0;i<lm.length;i++){var dI=lm[i];if(dI.getAttribute("face")==pi){by[by.length]=lm[i];}}for(var i=0;i<by.length;i++){var dI=by[i];pg(dI,aN);kJ(dI);nD(dI,aN,fN);dI.removeAttribute("face");var bd=dI.parentElement;if(bd.tagName=="FONT"){lG(bd);}if((bd.tagName=="FONT")||(bd.tagName=="SPAN")){if(bd.innerText==dI.innerText){bd.style.cssText=bd.style.cssText+";"+dI.style.cssText;bd.innerHTML=dI.innerHTML;by[i]=bd;continue;}}}var f1,f2;for(var i=0;i<by.length;i++){if(by[i]&&by[i].innerText){if(!f1){f1=by[i];}f2=by[i];}}var r1=EWEB.T.body.createTextRange();r1.moveToElementText(f1);var r2=EWEB.T.body.createTextRange();r2.moveToElementText(f2);r.setEndPoint("StartToStart",r1);r.setEndPoint("EndToEnd",r2);r.select();}else{if(["uppercase","lowercase","size"].IndexOf(aN)>=0){nL.og(aN,fN);}else{if(aN=="face"){aN="fontName";}EWEB.T.execCommand(aN,false,fN);}}};function pg(J,aN){oM(J,aN,"");var aY=J.children;for(var j=0;j<aY.length;j++){pg(aY[j],aN);if(aY[j].tagName=="FONT"){lG(aY[j]);}}};function kJ(J){var aY=J.children;for(var j=0;j<aY.length;j++){kJ(aY[j]);if((aY[j].tagName=="FONT")||(aY[j].tagName=="SPAN")){if((aY[j].style.cssText==""&&aY[j].className=="")||(aY[j].innerHTML=="")){aY[j].removeNode(false);kJ(J);return;}}}};function nD(J,aN,v){oM(J,aN,v);var aY=J.children;for(var j=0;j<aY.length;j++){if((aY[j].tagName=="SPAN")||(aY[j].tagName=="FONT")){nD(aY[j],aN,v);}}};function oM(J,aN,v){try{switch(aN){case "face":J.style.fontFamily=v;break;case "size":J.style.fontSize=v;break;case "color":J.style.color=v;break;default:break;}}catch(e){}};function lG(el){if(el.style.fontFamily==""){var s=el.getAttribute("face");if(s){el.style.fontFamily=s;}}el.removeAttribute("face");if(el.style.fontSize==""){var s=el.getAttribute("size");s=nq(s);if(s){el.style.fontSize=s;}}el.removeAttribute("size");if(el.style.color==""){var s=el.getAttribute("color");if(s){el.style.color=s;}}el.removeAttribute("color");};var nL=(function(){var kb,kL,hd,je;var bi=[];var aB,fp,cL,cO,ft,jT,jU;return{og:function(aV,fN){if(C.ai()!="Text"){return;}kL=false;kb=false;bi.length=0;hd=aV;je=fN;ft=(hd=="uppercase"||hd=="lowercase")?true:false;jT=false;jU=false;var bk=EWEB.aR.getSelection();var aD=bk.getRangeAt(0);aB=aD.startContainer;fp=aD.endContainer;cL=aD.startOffset;cO=aD.endOffset;if(aB==fp){if(aB.nodeType==1&&aB.tagName=="BODY"){jT=true;fp=this.me(aB);aB=this.oZ(aB);if(!aB|| !fp){return;}cL=0;cO=fp.nodeValue.length;this.jG(aD.startContainer);}else{jU=true;var fm=aB.nodeValue;if(ft){aB.nodeValue=fm.substring(0,cL)+this.jh(fm.substring(cL,cO))+fm.substring(cO);}else{var ao=aB.parentNode;var pm=fm.substring(0,cL);var oi=fm.substring(cL,cO);var qm=fm.substring(cO);if(ao.tagName.toUpperCase()=="SPAN"&&ao.innerHTML==oi){this.hx(ao);}else{var aU=this.ic(oi);aU.setAttribute("id","eWebEditor_Temp_Span_FontSize",0);ao.insertBefore(aU,aB);aB.nodeValue=qm;if(pm){var kO=EWEB.T.createTextNode(pm);ao.insertBefore(kO,aU);}}}}}else{this.jG(aD.commonAncestorContainer);}if(jT){EWEB.T.execCommand("SelectAll",false,null);}else{if(ft){aD.setStart(aB,cL);aD.setEnd(fp,cO);}else{if(jU){var ib=EWEB.T.getElementById("eWebEditor_Temp_Span_FontSize");if(ib){ib.removeAttribute("id");aD.selectNodeContents(ib.firstChild);}}else{aD.setStart(aB,aB.nodeValue.length);aD.setEnd(fp,0);}}}bk.removeAllRanges();bk.addRange(aD);EWEB.Focus();},jG:function(el){if(el==aB){kL=true;}if(kL){if(el==aB){if(ft){el.nodeValue=el.nodeValue.substring(0,cL)+this.jh(el.nodeValue.substring(cL));}else{bi[bi.length]=el;}}else if(el==fp){if(ft){el.nodeValue=this.jh(el.nodeValue.substring(0,cO))+el.nodeValue.substring(cO);}else{bi[bi.length]=el;for(var i=0;i<bi.length;i++){if(bi[i].nodeValue==""){continue;}if(i==0){var ao=bi[i].parentNode;if((ao.tagName.toUpperCase()=="SPAN")&&(bi[i].nodeValue.substring(cL)==ao.innerHTML)){this.hx(ao);}else{var v=bi[i].nodeValue.substring(cL);if(v){var aU=this.ic(v);ao.insertBefore(aU,bi[i].nextSibling);bi[i].nodeValue=bi[i].nodeValue.substring(0,cL);}}}else if(i==bi.length-1){var ao=bi[i].parentNode;if((ao.tagName.toUpperCase()=="SPAN")&&(bi[i].nodeValue.substring(0,cO)==ao.innerHTML)){this.hx(ao);}else{var v=bi[i].nodeValue.substring(0,cO);if(v){var aU=this.ic(v);ao.insertBefore(aU,bi[i]);bi[i].nodeValue=bi[i].nodeValue.substring(cO);}}}else{var ao=bi[i].parentNode;if((ao.tagName.toUpperCase()=="SPAN")&&(bi[i].nodeValue==ao.innerHTML)){this.hx(ao);}else{var aU=this.ic(bi[i].nodeValue);ao.replaceChild(aU,bi[i]);}}}}kb=true;}else if(el.nodeType==3){if(ft){el.nodeValue=this.jh(el.nodeValue);}else{bi[bi.length]=el;}}}if(el.hasChildNodes()){for(var i=0;i<el.childNodes.length;i++){if(kb){return;}this.jG(el.childNodes[i]);}}},jh:function(bM){switch(hd){case "uppercase":return bM.toUpperCase();break;case "lowercase":return bM.toLowerCase();break;case "size":return "<span id=\"eWebEditor_Temp_Span_FontSize\" style=\"font-size:"+je+"\">"+bM+"</span>";break;}},ic:function(bE){var kk=EWEB.T.createElement("span");var kO=EWEB.T.createTextNode(bE);kk.appendChild(kO);this.hx(kk);return kk;},hx:function(el){switch(hd){case "size":el.style.fontSize=je;break;case "face":el.style.fontName=je;break;}},oZ:function(el){if(el.nodeType==3){return el;}if(el.hasChildNodes()){for(var i=0;i<el.childNodes.length;i++){var bz=this.oZ(el.childNodes[i]);if(bz){return bz;}}}return null;},me:function(el){var bz;if(el.nodeType==3){bz=el;}if(el.hasChildNodes()){for(var i=0;i<el.childNodes.length;i++){var mj=this.me(el.childNodes[i]);if(mj){bz=mj;}}}if(bz){return bz;}else{return null;}}};})();var hZ={Execute:function(aN){if(C.ai()=="Control"){if(aN=="justifyleft"||aN=="justifyright"||aN=="justifycenter"){var bg=C.ax();bg.align=aN.substr(7);}if(aN!="justifyleft"&&aN!="justifyright"){EWEB.T.execCommand(aN,false,null);}}else{var a=new Array();var p=C.lF(["P","DIV","TD","TH"]);if(p){a[0]=p;}else{a=this.tE(["P","DIV"]);}if(a.length>0){for(var i=0;i<a.length;i++){p=a[i];if(aN=="justifyfull"){p.style.textAlign="justify";p.style.textJustify="inter-ideograph";}else{p.style.textAlign=aN.substr(7);p.style.textJustify="";}p.removeAttribute("align");}}else{EWEB.T.execCommand(aN,false,null);}}EWEB.Focus();ci.eW();},tE:function(eE){var gG=new Array();for(var i=0;i<eE.length;i++){var a=EWEB.T.body.getElementsByTagName(eE[i]);for(var j=0;j<a.length;j++){if(C.ww(a[j])){gG[gG.length]=a[j];}}}return gG;}};var kC=new Object();kC.Execute=function(aN){var iu=false;if(F.as){var np=function(){iu=true;};var pY='on'+aN.toLowerCase();EWEB.T.body.attachEvent(pY,np);EWEB.T.execCommand(aN,false,null);EWEB.T.body.detachEvent(pY,np);}else{try{iu=EWEB.T.execCommand(aN,false,null);}catch(e){}}if(!iu){ec.OpenDialog("prompt.htm?prompt="+lang['MsgSafe'+aN]);}};var kQ=new Object();kQ.Execute=function(){var bQ=window.frameElement;var kN=parent.document.documentElement;var hm=parent.document.body.style;var bd;if(!this.hM){R.az(parent,'resize',iR);this.oJ=R.gL(parent);bd=bQ;while((bd=bd.parentNode)){if(bd.nodeType==1){bd._ewebSavedStyles=R.oE(bd);}}if(F.as){this.ss=kN.style.overflow;kN.style.overflow='hidden';hm.overflow='hidden';}else{hm.overflow='hidden';hm.width='0px';hm.height='0px';}this.ug=R.oE(bQ);var hl=R.eF(parent);bQ.style.position="absolute";bQ.offsetLeft;bQ.style.zIndex=9998;bQ.style.left="0px";bQ.style.top="0px";bQ.style.width=hl.Width+"px";bQ.style.height=hl.Height+"px";if(!F.as){bQ.style.borderRight=bQ.style.borderBottom="9999px solid white";bQ.style.backgroundColor="white";}parent.scrollTo(0,0);var gz=R.vU(parent,bQ);if(gz.x!=0){bQ.style.left=(-1*gz.x)+"px";}if(gz.y!=0){bQ.style.top=(-1*gz.y)+"px";}this.hM=true;}else{R.hf(parent,'resize',iR);bd=bQ;while((bd=bd.parentNode)){if(bd._ewebSavedStyles){R.lO(bd,bd._ewebSavedStyles);bd._ewebSavedStyles=null;}}if(F.as){kN.style.overflow=this.ss;}R.lO(bQ,this.ug);parent.scrollTo(this.oJ.X,this.oJ.Y);this.hM=false;}this.eD();if(EWEB.ae=="EDIT"&& !F.as){EWEB.lo();}EWEB.Focus();};kQ.eD=function(){var cp=ci.hV("other","Maximize");for(var j=0;j<cp.length;j++){var el=cp[j];if(this.hM){el.dj="on";el.className="TB_Btn_Down";}else{el.dj=null;el.className="TB_Btn";}}};function iR(){var hl=R.eF(parent);var bQ=window.frameElement;bQ.style.width=hl.Width+'px';bQ.style.height=hl.Height+'px';};function ue(){if(!hH()){return;}if(!eY(true)){return;}aZ.Capture("");window.setTimeout("nK()",100);};function nK(){try{if(aZ.Status!="ok"){window.setTimeout("nK()",100);return;}}catch(e){return}if(aZ.Error=="cancel"){return;}if(es()){return;}var fh=aZ.Body;insertHTML(fh);aZ=null;};function oX(){if(config.AutoDetectPaste=="2"){window.setTimeout("ix()",10);return;}if(F.as){if(config.AutoDetectPaste=="1"){if(!eY(true)){return false;}var an=aZ.GetClipboardFlag();var fB=an.split("|");if(fB[5]=="1"){window.setTimeout("kF()",10);return false;}else if(fB[5]=="2"){window.setTimeout("uH()",10);return false;}else if(fB[5]=="3"||fB[5]=="4"){mB();window.setTimeout("localUpload()",10);return false;}else if(fB[0]=="1"||fB[3]=="1"){window.setTimeout("tG('"+an+"')",10);return false;}}mB();}else{aK("pastegecko.htm");}};function mB(){var V=sD();insertHTML(V);};function tG(an){aK("pasteoption.htm?flag="+an,true);};function kF(){if(F.as){if(config.AutoDonePasteWord){aK("importword.htm?action=paste&autodone=1",true,true,true);}else{/*aK("importword.htm?action=paste",true);*/cleanAndPaste(sD());}}else{aK("pastegecko.htm?action=word");}};function uH(){if(config.AutoDonePasteExcel){aK("importexcel.htm?action=paste&autodone=1",true,true,true);}else{aK("importexcel.htm?action=paste",true);}};function ix(){EWEB.Focus();ap.Save();if(F.as){var V=fn(clipboardData.getData("Text"));insertHTML(V);}else{aK("pastegecko.htm?action=text");}ap.Save();EWEB.Focus();};function cleanAndPaste(html){html=html.replace(/<\/?SPAN[^>]*>/gi,"");html=html.replace(/<(\w[^>]*) class=([^ |>]*)([^>]*)/gi,"<$1$3");html=html.replace(/<(\w[^>]*) style="([^"]*)"([^>]*)/gi,"<$1$3");html=html.replace(/<(\w[^>]*) lang=([^ |>]*)([^>]*)/gi,"<$1$3");html=html.replace(/<\\?\?xml[^>]*>/gi,"");html=html.replace(/<\/?\w+:[^>]*>/gi,"");html=html.replace(/&nbsp;/," ");insertHTML(html)};function sD(){var cR=$("eWebEditor_Temp_HTML");cR.innerHTML="";var mP=document.body.createTextRange();mP.moveToElementText(cR);mP.execCommand("Paste");var V=cR.innerHTML;cR.innerHTML="";return V;};var kh={Execute:function(){this.gN();this.cV= !this.cV;this.eD();},jJ:function(){this.gN();if(this.cV){this.eD();}},gN:function(){if(typeof(this.cV)=="undefined"){this.cV=(config.ShowBorder=="0")?false:true;}},eD:function(){var K=EWEB.T.getElementsByTagName("TABLE");for(var i=0;i<K.length;i++){var el=K[i];if(this.cV){el.className+=' ewebeditor__showtableborders';}else{el.className=el.className.replace(/(^| )ewebeditor__showtableborders/gi,'');}}var cp=ci.hV("other","ShowBorders");for(var j=0;j<cp.length;j++){var el=cp[j];if(this.cV){el.dj="on";el.className="TB_Btn_Down";}else{el.dj=null;el.className="TB_Btn";}}}};var jK={Execute:function(){this.gN();this.cV= !this.cV;this.eD();},jJ:function(){this.gN();if(this.cV){this.eD();}},gN:function(){if(typeof(this.cV)=="undefined"){this.cV=(config.ShowBlock=="1")?true:false;}},eD:function(){var dK=EWEB.T.body;if(this.cV){dK.className+=' ewebeditor__showblocks';}else{dK.className=dK.className.replace(/(^| )ewebeditor__showblocks/gi,'');}var cp=ci.hV("other","ShowBlocks");for(var j=0;j<cp.length;j++){var el=cp[j];if(this.cV){el.dj="on";el.className="TB_Btn_Down";}else{el.dj=null;el.className="TB_Btn";}}}};var CL=(function(){var cV=false;var BK;var BZ;var Cq;var Cb;var Bv;var Bl;var CF;var BE;var xe;var yS;var Bf=function(){var cp=ci.hV("other","FormatBrush");for(var j=0;j<cp.length;j++){var el=cp[j];if(cV){el.dj="on";el.className="TB_Btn_Down";}else{el.dj=null;el.className="TB_Btn";}}};var oU=function(aV){var v;switch(aV){case "fontsize":v=C.CP();break;case "bold":case "italic":case "underline":case "strikethrough":case "superscript":case "subscript":v=EWEB.T.queryCommandState(aV);break;case "fontname":v=EWEB.T.queryCommandValue(aV);break;case "forecolor":case "backcolor":if(!F.as&& !F.AM&&aV=="backcolor"){aV="hiliteColor";}v=EWEB.T.queryCommandValue(aV);if(F.as){v=BX(v);}break;}if(v==null){v="";}return v;};var BX=function(Cs){if(Cs==null){return "";}var aQ=Cs.toString(16);switch(aQ.length){case 1:aQ="0"+aQ+"0000";break;case 2:aQ=aQ+"0000";break;case 3:aQ=aQ.substring(1,3)+"0"+aQ.substring(0,1)+"00";break;case 4:aQ=aQ.substring(2,4)+aQ.substring(0,2)+"00";break;case 5:aQ=aQ.substring(3,5)+aQ.substring(1,3)+"0"+aQ.substring(0,1);break;case 6:aQ=aQ.substring(4,6)+aQ.substring(2,4)+aQ.substring(0,2);break;default:aQ="";}return '#'+aQ;};var rR=function(CJ,aV){var CB=oU(aV);if(CJ!=CB){format(aV);}if(!CJ&& !CB){format(aV);format(aV);}};return{Ce:function(){return cV;},Execute:function(){if(!cV){BK=oU("fontname");BZ=oU("fontsize");Cq=oU("bold");Cb=oU("italic");Bv=oU("underline");Bl=oU("strikethrough");CF=oU("superscript");BE=oU("subscript");xe=oU("forecolor");yS=oU("backcolor");}cV= !cV;Bf();},Stop:function(){if(!cV){return;}cV=false;Bf();},Bi:function(){if(!cV){return;}if(C.ai()!="Text"){return;}var BC;if(F.as){BC=C.bG().createRange().text;}else{BC=C.bG()+"";}if(!BC){return;}if(BK&&BK!=oU("fontname")){fq('face',BK);}rR(Cq,"bold");rR(Cb,"italic");rR(Bv,"underline");rR(Bl,"strikethrough");rR(CF,"superscript");rR(BE,"subscript");if(xe&&xe!=oU("forecolor")){if(F.as){fq('color',xe);}else{fq('forecolor',xe);}}if(yS&&yS!=oU("backcolor")){if(F.as){format('backcolor',yS);}else{format('hiliteColor',yS);}}if(BZ&&BZ!=oU("fontsize")){fq('size',BZ);}}};})();function ow(an){if(!hH()){return;}switch(an){case "word":aK('importword.htm',true);break;case "excel":aK('importexcel.htm',true);break;}};var eO={fv:function(an){switch(an){case "inputtext":insertHTML('<input type="text">');break;case "textarea":insertHTML('<textarea></textarea>');break;case "radio":insertHTML('<input type="radio">');break;case "checkbox":insertHTML('<input type="checkbox">');break;case "select":insertHTML('<select></select>');break;case "button":insertHTML('<input type="button">');break;}}};function tp(){EWEB.aR.print();};var R=new Object();R.Clone=function(J){var _clone;if(J&&(J instanceof Array)){_clone=[];for(var i=0;i<J.length;i++){_clone[i]=this.Clone(J[i]);}return _clone;}if(J===null||(typeof(J)!='object')||(J instanceof String)||(J instanceof Number)||(J instanceof Boolean)||(J instanceof Date)||(J instanceof RegExp)){return J;}_clone=new J.constructor();for(var propertyName in J){var property=J[propertyName];_clone[propertyName]=this.Clone(property);}return _clone;};R.fR=function(document){return("CSS1Compat"==(document.compatMode||(F.ik?"CSS1Compat":null)));};R.hh=function(element){element.style.cssText="margin:0;"+"padding:0;"+"border:0;"+"background-color:transparent;"+"background-image:none;";};R.dV=function(element){return element.ownerDocument||element.document;};R.mh=function(element){return this.mD(this.dV(element));};R.mD=function(document){if(F.ik&& !document.parentWindow){this.qJ(window.top);}return document.parentWindow||document.defaultView;};R.qJ=function(fi){if(fi.document){fi.document.parentWindow=fi;}for(var i=0;i<fi.frames.length;i++){R.qJ(fi.frames[i]);}};R.lJ=function(){var eB=window.parent;while(eB.parent&&eB.parent!=eB){try{if(eB.parent.document.domain!=document.domain){break;}if(eB.parent.document.getElementsByTagName("frameset").length>0){break;}}catch(e){break;}eB=eB.parent;}return eB;};R.hg=function(w,node){var x=0;var y=0;var bN=node;var ku=null;var hn=R.mh(bN);while(bN&& !(hn==w&&(bN==w.document.body||bN==w.document.documentElement))){x+=bN.offsetLeft-bN.scrollLeft;y+=bN.offsetTop-bN.scrollTop;if(!F.jr){var fr=ku;while(fr&&fr!=bN){x-=fr.scrollLeft;y-=fr.scrollTop;fr=fr.parentNode;}}ku=bN;if(bN.offsetParent){bN=bN.offsetParent;}else{if(hn!=w){bN=hn.frameElement;ku=null;if(bN){hn=bN.contentWindow.parent;}}else{bN=null;}}}if(R.ce(w.document.body,'position')!='static'||(F.as&&R.vN(node)==null)){x+=w.document.body.offsetLeft;y+=w.document.body.offsetTop;}return{"x":x,"y":y};};R.vU=function(w,node){var pos=this.hg(w,node);var scroll=R.gL(w);pos.x-=scroll.X;pos.y-=scroll.Y;return pos;};R.zD=function(element,rE){var window=this.mh(element);var oc=this.eF(window).Height;var offset=oc* -1;if(rE===false){offset+=element.offsetHeight||0;offset+=parseInt(this.ce(element,'marginBottom')||0,10)||0;}var st=this.hg(window,element);offset+=st.y;var rf=this.gL(window).Y;if(offset>0&&(offset>rf||offset<rf-oc)){window.scrollTo(0,offset);}};R.ns=function(bY){if(!bY||bY.nodeType!=1||bY.tagName.toLowerCase()!='form'){return[];}var fE=[];var lK=['style','className'];for(var i=0;i<lK.length;i++){var name=lK[i];if(bY.elements.namedItem(name)){var kU=bY.elements.namedItem(name);fE.push([kU,kU.nextSibling]);bY.removeChild(kU);}}return fE;};R.lU=function(bY,fE){if(!bY||bY.nodeType!=1||bY.tagName.toLowerCase()!='form'){return;}if(fE.length>0){for(var i=fE.length-1;i>=0;i--){var node=fE[i][0];var nH=fE[i][1];if(nH){bY.insertBefore(node,nH);}else{bY.appendChild(node);}}}};R.vN=function(element){var cw=element;while(cw!=R.dV(cw).documentElement){if(this.ce(cw,'position')!='static'){return cw;}if(cw==R.dV(cw).documentElement&&tO!=w){cw=tO.frameElement;}else{cw=cw.parentNode;}}return null;};R.oQ=function(func,vp,hO,jC,kz){return(kz||window).setTimeout(function(){if(jC){func.apply(hO,[].concat(jC));}else{func.apply(hO);}},vp);};R.za=function(func,hO,jC,kz){if(func){this.oQ(func,0,hO,jC,kz);}};R.cP=function(element,nT){var style=element.style;for(var pf in nT){style[pf]=nT[pf];}};R.cE=function(node,vq){if(vq){var qq;while((qq=node.firstChild)){node.parentNode.insertBefore(node.removeChild(qq),node);}}return node.parentNode.removeChild(node);};R.tz=function(bz,mL){while(bz&&bz.tagName&&bz.tagName!="BODY"){if(bz.tagName.toUpperCase()==mL){return bz;}bz=bz.parentNode;}return null;};R.lE=function(fi){fi.$=function(Cu){return fi.document.getElementById(Cu);};};R.iO=function(){if(F.as){if(F.xZ){return "javascript: '';";}else{return "";}}else{return "javascript: void(0);";}};R.aw=function(e){if(F.as){try{e.returnValue=false;e.cancelBubble=true;e.keyCode=0;}catch(er){}return false;}else{if(e){e.preventDefault();e.stopPropagation();}}};R.az=function(jP,pY,v_Listener){if(F.as){jP.attachEvent("on"+pY,v_Listener);}else{jP.addEventListener(pY,v_Listener,false);}};R.hf=function(jP,pY,v_Listener){if(F.as){jP.detachEvent("on"+pY,v_Listener);}else{jP.removeEventListener(pY,v_Listener,false);}};R.eF=function(win){if(F.as){var nm;var cl=win.document.documentElement;if(cl&&cl.clientWidth){nm=cl;}else{nm=win.document.body;}if(nm){return{Width:nm.clientWidth,Height:nm.clientHeight};}else{return{Width:0,Height:0};}}else{return{Width:win.innerWidth,Height:win.innerHeight};}};R.gL=function(pK){if(F.as){var cl=pK.document;var fs={X:cl.documentElement.scrollLeft,Y:cl.documentElement.scrollTop};if(fs.X>0||fs.Y>0){return fs;}return{X:cl.body.scrollLeft,Y:cl.body.scrollTop};}else{return{X:pK.pageXOffset,Y:pK.pageYOffset};}};R.rN=function(element,opacity){if(F.as&& !F.BI){opacity=Math.round(opacity*100);element.style.filter=(opacity>100?"":"progid:DXImageTransform.Microsoft.Alpha(opacity="+opacity+")");}else{element.style.opacity=opacity;}};R.ce=function(element,propertyName){if(F.as){propertyName=propertyName.replace(/\-(\w)/g,function(CC,p1){return p1.toUpperCase();});return element.currentStyle[propertyName];}else{try{return element.ownerDocument.defaultView.getComputedStyle(element,"").getPropertyValue(propertyName);}catch(e){}}};R.ko=function(kG){if(F.as){kG.unselectable='on';var e,i=0;while((e=kG.all[i++])){if(e.getAttribute('eweb_donotdisableselect',2)=='true'){i+=e.all.length;continue;}switch(e.tagName){case 'IFRAME':case 'TEXTAREA':case 'INPUT':case 'SELECT':break;default:e.unselectable='on';}}}else{if(F.jo){kG.style.MozUserSelect='-moz-none';}else if(F.ik){kG.style.KhtmlUserSelect='none';}else{kG.style.userSelect='none';}var K=kG.getElementsByTagName("*");for(var i=0;i<K.length;i++){switch(K[i].tagName){case "INPUT":case "TEXTAREA":K[i].style.MozUserSelect="text";break;default:}}}};R.oE=function(element){var data=R.ns(element);var ky=new Object();if(element.className.length>0){ky.Class=element.className;element.className='';}if(F.as){var nk=element.style.cssText;if(nk.length>0){ky.Inline=nk;element.style.cssText='';}element.style.position='static';}else{var nk=element.getAttribute('style');if(nk&&nk.length>0){ky.Inline=nk;element.setAttribute('style','',0);}}R.lU(element,data);return ky;};R.lO=function(element,le){var data=R.ns(element);if(F.as){element.className=le.Class||'';element.style.cssText=le.Inline||'';}else{element.className=le.Class||'';if(le.Inline){element.setAttribute('style',le.Inline,0);}else{element.removeAttribute('style',0);}}R.lU(element,data);};var C=new Object();C.lF=function(eE){var el=null;if(C.ai()!="Control"){el=C.cI();if(el.tagName=="HTML"){return null;}while(eE.IndexOf(el.tagName.toUpperCase())<0){if(el.tagName.toUpperCase()=="BODY"){el=null;break;}el=el.parentNode;}}return el;};C.ai=function(){if(F.as){try{var vt=C.bG().type;if(vt=='Control'||vt=='Text'){return vt;}if(this.bG().createRange().parentElement){return 'Text';}}catch(e){}return 'None';}else{var type='Text';var At={img:1,hr:1,li:1,table:1,tr:1,td:1,embed:1,object:1,ol:1,ul:1};var bk;try{bk=this.bG();}catch(e){}if(bk&&bk.rangeCount==1){var range=bk.getRangeAt(0);if(range.startContainer==range.endContainer&&(range.endOffset-range.startOffset)==1&&range.startContainer.nodeType==1&&At[range.startContainer.childNodes[range.startOffset].nodeName.toLowerCase()]){type='Control';}}return type;}};C.ax=function(){if(F.as){if(this.ai()=='Control'){var oRange=this.bG().createRange();if(oRange&&oRange.item){return this.bG().createRange().item(0);}}return null;}else{var selection= ! !EWEB.aR&&this.bG();if(!selection||selection.rangeCount<1){return null;}var range=selection.getRangeAt(0);if(range.startContainer!=range.endContainer||range.startContainer.nodeType!=1||range.startOffset!=range.endOffset-1){return null;}var node=range.startContainer.childNodes[range.startOffset];if(node.nodeType!=1){return null;}return node;}};C.cI=function(){if(F.as){switch(this.ai()){case 'Control':var el=C.ax();return el?el.parentElement:null;case 'None':return null;default:return this.bG().createRange().parentElement();}}else{if(this.ai()=='Control'){return C.ax().parentNode;}else{var af=this.bG();if(af){var oRange=af.getRangeAt(0);if(af.anchorNode&&af.anchorNode==af.focusNode){if(oRange.collapsed||oRange.startContainer.nodeType==3){return af.anchorNode.parentNode;}else{return af.anchorNode;}}return oRange.commonAncestorContainer;}}return null;}};C.xt=function(pU){if(F.as){switch(this.ai()){case 'Control':var el=C.ax();return el?el.parentElement:null;case 'None':return null;default:var doc=EWEB.T;var range=doc.selection.createRange();range.collapse(pU!==false);var el=range.parentElement();return R.dV(el)==doc?el:null;}}else{if(!EWEB.aR){return null;}if(this.ai()=='Control'){return C.ax().parentNode;}else{var af=this.bG();if(af&&af.rangeCount>0){var range=af.getRangeAt(pU?0:(af.rangeCount-1));var element=pU?range.startContainer:range.endContainer;return(element.nodeType==1?element:element.parentNode);}}return null;}};C.vR=function(node){if(F.as){EWEB.Focus();this.bG().empty();var oRange;try{oRange=EWEB.T.body.createControlRange();oRange.addElement(node);}catch(e){oRange=EWEB.T.body.createTextRange();oRange.moveToElementText(node);}oRange.select();}else{var oRange=EWEB.T.createRange();oRange.selectNode(node);var af=this.bG();af.removeAllRanges();af.addRange(oRange);}};C.Empty=function(){if(F.as){this.bG().empty();}else{this.bG().removeAllRanges();}};C.Collapse=function(nV){if(F.as){EWEB.Focus();if(this.ai()=='Text'){var oRange=this.bG().createRange();oRange.collapse(nV==null||nV===true);oRange.select();}}else{var af=this.bG();if(nV==null||nV===true){af.collapseToStart();}else{af.collapseToEnd();}}};C.zp=function(nodeTagName){if(F.as){var cr;if(this.bG().type=="Control"){cr=this.ax();}else{var oRange=this.bG().createRange();cr=oRange.parentElement();}while(cr){if(cr.nodeName.IEquals(nodeTagName))return true;cr=cr.parentNode;}return false;}else{var cr=this.ax();if(!cr&&EWEB.aR){try{cr=this.bG().getRangeAt(0).startContainer;}catch(e){}}while(cr){if(cr.nodeType==1&&cr.nodeName.IEquals(nodeTagName))return true;cr=cr.parentNode;}return false;}};C.AG=function(nodeTagName){if(F.as){var io,oRange;if(!EWEB.T)return null;if(this.bG().type=="Control"){oRange=this.bG().createRange();for(i=0;i<oRange.length;i++){if(oRange(i).parentNode){io=oRange(i).parentNode;break;}}}else{oRange=this.bG().createRange();io=oRange.parentElement();}while(io&& !io.nodeName.Equals(nodeTagName)){io=io.parentNode;}return io;}else{var io;var cr=this.ax();if(!cr){cr=this.bG().getRangeAt(0).startContainer;}while(cr){if(cr.nodeName.IEquals(nodeTagName)){return cr;}cr=cr.parentNode;}return null;}};C.Delete=function(){var af=this.bG();if(F.as){if(af.type.toLowerCase()!="none"){af.clear();}}else{for(var i=0;i<af.rangeCount;i++){af.getRangeAt(i).deleteContents();}}return af;};C.bG=function(){if(F.as){this.Restore();return EWEB.T.selection;}else{return EWEB.aR.getSelection();}};C.Save=function(b_Lock){if(!F.as){return;}var qs=EWEB.T;if(!qs){return;}if(this.yw){return;}this.yw= ! !b_Lock;var selection=qs.selection;var range;if(selection){try{range=selection.createRange();}catch(e){}if(range){if(range.parentElement&&R.dV(range.parentElement())!=qs){range=null;}else if(range.item&&R.dV(range.item(0))!=qs){range=null;}}}this.sN=range;};C.zw=function(fH){var o_Rng=fH.createRange();if(!o_Rng){return null;}else if(o_Rng.item){return R.dV(o_Rng.item(0));}else{return R.dV(o_Rng.parentElement());}};C.Restore=function(){if(!F.as){return;}if(this.sN){EWEB.yB=true;try{if(this.zw(EWEB.T.selection)==EWEB.T){EWEB.yB=false;return;}this.sN.select();}catch(e){}EWEB.yB=false;}};C.Release=function(){if(!F.as){return;}this.yw=false;delete this.sN;};C.ww=function(el){if(F.as){var iP,gF;iP=EWEB.T.selection.createRange();gF=EWEB.T.body.createTextRange();gF.moveToElementText(el);if(iP.inRange(gF)){return true;}else{if(((iP.compareEndPoints("StartToEnd",gF)<0)&&(iP.compareEndPoints("StartToStart",gF)>0))||((iP.compareEndPoints("EndToStart",gF)>0)&&(iP.compareEndPoints("EndToEnd",gF)<0))){return true;}}return false;}else{var iP,gF;iP=C.bG().getRangeAt(0);gF=EWEB.T.createRange();gF.selectNodeContents(el);if((gF.compareBoundaryPoints(Range.START_TO_END,iP)>=0)&&(gF.compareBoundaryPoints(Range.END_TO_START,iP)<=0)){return true;}return false;}};C.CP=function(){if(C.ai()=="Control"){return "";}var vf=function(){if(C.ai()=="Control"){return "";}var r="";if(F.as){var aD=C.bG().createRange();if(aD.text.length<=1){return aD.parentElement().currentStyle.fontSize;}var html=aD.htmlText;html=html.replace(/<[^>]+>/gi," ");html=html.replace(/(&nbsp\;|\s)+/gi," ");html=html.replace(/(^\s*)|(\s*$)/gi,"");var kr=html.split(" ");var pZ=aD.getBookmark();aD.collapse();for(var i=0;i<kr.length;i++){if(!kr[i]){continue;}var b=aD.findText(kr[i]);if(b){var v=aD.parentElement().currentStyle.fontSize;if((r!="")&&(r!=v)){r="";break;}r=v;aD.collapse(false);}else{break;}}aD.moveToBookmark(pZ);}else{var eU=C.cI();if(!eU){return "";}var ad=C.bG().getRangeAt(0);var fG=EWEB.T.createRange();r=R.ce(eU,"font-size");var K=eU.getElementsByTagName("*");for(var i=0;i<K.length;i++){var el=K[i];fG.selectNodeContents(el);if((fG.compareBoundaryPoints(Range.START_TO_END,ad)>=0)&&(fG.compareBoundaryPoints(Range.END_TO_START,ad)<=0)){var v=R.ce(el,"font-size");if(r!=v){r="";break;}}}if(r!=""){}}return r;};var v;if(F.as){v=EWEB.T.queryCommandValue("FontSize");if(v){v=nq(v);}}if(!v){v=vf();}return v;}; 