function HideEktronEditorsMenu(a){if($ektron("#"+a).css("display")==="block"){$ektron("#"+a).slideUp("fast")}}function ShowEktronEditorsMenu(a){var b=$ektron("ul.EktronEditorsMenu");for(i=0;i<b.length;i++){if($ektron(b[i]).attr("id")!==a){$ektron(b[i]).slideUp("fast")}}if($ektron("#"+a).css("display")==="none"){var c=true;if($ektron("#"+a).parent().parent().find("iframe").length>0){c=false}if($ektron("#"+a).parent().parent().find("object").length>0){c=false}if(c==false){$ektron("#"+a).attr("class","EktronEditorsMenu EktronEditorsMenuNotLayered");$ektron("#"+a).css("display","block")}else{$ektron("#"+a).slideDown("fast")}}}function xBrowserReturnObjById(a){if(document.getElementById){var b=document.getElementById(a)}else if(document.all){var b=document.all[a]}else if(document.layers){var b=document.layers[a]}return b}function EkTbStopBubble(a,b){a.cancelBubble=true}function EkTbShowToolbar(a,b){if(!m_bEkTbReady)return false;var c=true;var d="";var e="";var f=0;var g=0;if(document.all){d=a.toElement;e=a.srcElement;if(a.y==event.clientY){g=a.y+(EkTbFindParentPositionTop(e,m_EkTbStopAtRoot,false)-EkTbFindParentPositionTop(e,m_EkTbStopAtCss,false)+EkTbGetScrollTop());f=a.x+(EkTbFindParentPositionLeft(e,m_EkTbStopAtRoot,false)-EkTbFindParentPositionLeft(e,m_EkTbStopAtCss,false)+EkTbGetScrollLeft())}else{g=event.clientY+EkTbFindParentPositionTop(e,m_EkTbStopAtRoot)-EkTbFindParentPositionTop(e,m_EkTbStopAtCss)+EkTbGetScrollTop();if(event.screenX!=a.clientX){f=event.clientX+(a.x+(EkTbFindParentPositionLeft(e,m_EkTbStopAtRoot,false)-EkTbFindParentPositionLeft(e,m_EkTbStopAtCss,false)+EkTbGetScrollLeft()))-a.x}else{f=event.screenX}}}else{d=a.relatedTarget;e=a.target;g=a.pageY;f=a.pageX}if(!a.ctrlKey){var h=b.id.split("_");var i=EkTbFindParentPositionLeft(document.getElementById("EkTbBase_"+h[1]),m_EkTbStopAtRoot,true)+document.getElementById("EkTbBase_"+h[1]).offsetWidth;if(f>i){f=i}document.getElementById("EkTbToolbar_"+h[1]).style.top=g+"px";document.getElementById("EkTbToolbar_"+h[1]).style.left=f+"px";document.getElementById("EkTbToolbar_"+h[1]).style.display="";c=false}return c}function EkTbMacShowToolbar(a,b){if(!m_bEkTbReady)return false;var c=true;if(navigator.userAgent.indexOf("Mac")>-1){if(a.shiftKey){c=EkTbShowToolbar(a,b)}}return c}function EkTbIsStopTag(a,b){if(!m_bEkTbReady)return false;var c=false;if(a.style.position.toLowerCase()=="relative"&&b&m_EkTbStopAtCss||a.style.position.toLowerCase()=="absolute"&&b&m_EkTbStopAtOffset){if(!document.all){if(a.tagName.toLowerCase()!="table"){c=true}}else{c=true}}return c}function EkTbIsChild(a,b){if(!m_bEkTbReady)return false;var c=false;var d="";if(a){if(typeof a.id=="string"&&(a.id.indexOf("EkTbToolbar_")>-1||a.id.indexOf("EkTbLeftBar_")>-1||a.id.indexOf("EkTbRightBar_")>-1||a.id.indexOf("EkTbTopBar_")>-1||a.id.indexOf("EkTbBottomBar_")>-1)){c=true}else{if(a.parentNode){while(a.parentNode){a=a.parentNode;if(b.id.indexOf("EkTb")>-1){d=b.id.split("_")}else{d=new Array;d[0]="";d[1]=""}if(a==b||a==document.getElementById("EkTbToolbar_"+d[1])||a==document.getElementById("EkTbLeftBar_"+d[1])||a==document.getElementById("EkTbRightBar_"+d[1])||a==document.getElementById("EkTbTopBar_"+d[1])||a==document.getElementById("EkTbBottomBar_"+d[1])){c=true;break}}}}}return c}function EkTbFindLeftDifference(a,b){if(!m_bEkTbReady)return false;var c=0;if(a!=b){c+=a.offsetLeft;if(a.offsetParent){while(a.offsetParent&&a!=b){c+=a.offsetLeft;a=a.offsetParent}}}return c}function EkTbFindTopDifference(a,b){if(!m_bEkTbReady)return false;var c=0;if(a!=b){c+=a.offsetTop;if(a.offsetParent){while(a.offsetParent&&a!=b){c+=a.offsetTop;a=a.offsetParent}}}return c}function EkTbIsInQuirksMode(){return 0==document.documentElement.clientHeight}function EkTbGetScrollLeft(){if(EkTbIsInQuirksMode()){return document.body.scrollLeft}else{return document.documentElement.scrollLeft}}function EkTbGetScrollTop(){if(EkTbIsInQuirksMode()){return document.body.scrollTop}else{return document.documentElement.scrollTop}}function EkTbFindParentPositionTop(a,b,c){if(!m_bEkTbReady)return false;var d=0;if(a.offsetParent){while(a&&null!=a.offsetTop){if(b!=m_EkTbStopAtRoot&&EkTbIsStopTag(a,b)){break}if(c||a.style&&a.style.position&&a.style.position&&"relative"!=a.style.position.toLowerCase()&&"absolute"!=a.style.position.toLowerCase()){d+=a.offsetTop}a=a.offsetParent}}else if(a.x){curleft+=a.x}return d}function EkTbFindParentPositionLeft(a,b,c){if(!m_bEkTbReady)return false;var d=0;if(a.offsetParent){while(a&&null!=a.offsetLeft){if(b!=m_EkTbStopAtRoot&&EkTbIsStopTag(a,b)){break}if(c||a.style&&a.style.position&&a.style.position&&"relative"!=a.style.position.toLowerCase()&&"absolute"!=a.style.position.toLowerCase()){d+=a.offsetLeft}a=a.offsetParent}}else if(a.x){d+=a.x}return d}function EkTbCancelOff(MyObj){if(!m_bEkTbReady)return false;var tmpArray=MyObj.id.split("_");var tmpTimeout=eval("m_EkTbTimeout_"+tmpArray[1]);if(tmpTimeout!=null){clearTimeout(tmpTimeout);eval("m_EkTbTimeout_"+tmpArray[1]+" = null;")}}function EkTbOffNow(MyObjId){if(!m_bEkTbReady)return false;try{var tmpArray=MyObjId.split("_");if(eval("m_EkTbTimeout_"+tmpArray[1]+" != null")){eval("m_EkTbTimeout_"+tmpArray[1]+" = null")}document.getElementById("EkTbLeftBar_"+tmpArray[1]).style.display="none";document.getElementById("EkTbRightBar_"+tmpArray[1]).style.display="none";document.getElementById("EkTbTopBar_"+tmpArray[1]).style.display="none";document.getElementById("EkTbBottomBar_"+tmpArray[1]).style.display="none";document.getElementById("EkTbToolbar_"+tmpArray[1]).style.display="none"}catch(e){}}function EkTbOff(MyObjId){if(!m_bEkTbReady)return false;try{var tmpArray=MyObjId.split("_");if(eval("m_EkTbTimeout_"+tmpArray[1]+" != null")){eval("m_EkTbTimeout_"+tmpArray[1]+" = null");document.getElementById("EkTbLeftBar_"+tmpArray[1]).style.display="none";document.getElementById("EkTbRightBar_"+tmpArray[1]).style.display="none";document.getElementById("EkTbTopBar_"+tmpArray[1]).style.display="none";document.getElementById("EkTbBottomBar_"+tmpArray[1]).style.display="none";document.getElementById("EkTbToolbar_"+tmpArray[1]).style.display="none"}}catch(e){}}function EkTbRollOut(e,MyObj){if(!m_bEkTbReady)return false;var toElement="";var srcElement="";if(document.all){toElement=e.toElement;srcElement=e.srcElement}else{toElement=e.relatedTarget;srcElement=e.target}if(srcElement.id!=MyObj.id&&!EkTbIsChild(srcElement,MyObj)){return}if(toElement==null||!(EkTbIsChild(toElement,MyObj)||MyObj.id==toElement.id)){var tmpArray=MyObj.id.split("_");eval("m_EkTbTimeout_"+tmpArray[1]+" = setTimeout(\"EkTbOff('"+MyObj.id+"')\", m_EkTbMenuOffDelay_"+tmpArray[1]+")")}}function EkTbRollOver(e,MyObj){if(!m_bEkTbReady)return false;var top=0;var tmpTop=0;var left=0;var tmpLeft=0;var width=0;var height=0;var toolbarNumArray=MyObj.id.split("_");var automaticBorder=true;var outsideBorder=true;var menuBorderWidth=3;var localTimeout=null;var ekTbOuterElement=null;if(m_EkTbLastObj&&m_EkTbLastObj!=MyObj){EkTbOffNow(m_EkTbLastObj.id)}m_EkTbLastObj=MyObj;eval("localTimeout = m_EkTbTimeout_"+toolbarNumArray[1]+";");if(localTimeout!=null){localTimeout=clearTimeout(localTimeout);eval("m_EkTbTimeout_"+toolbarNumArray[1]+" = localTimeout;")}if(IsPlatformMac()){ekTbOuterElement=xBrowserReturnObjById("EkTbOuterElmt_"+toolbarNumArray[1]);if(ekTbOuterElement!=null){height=ekTbOuterElement.offsetHeight}else{height=MyObj.offsetHeight}}else{height=MyObj.offsetHeight}tmpLeft=EkTbFindParentPositionLeft(MyObj,m_EkTbStopAtRoot,true);width=MyObj.offsetWidth;tmpTop=EkTbFindParentPositionTop(MyObj,m_EkTbStopAtRoot,true);eval("automaticBorder = m_EkTbAutomaticOutsideBorder_"+toolbarNumArray[1]+";");eval("outsideBorder = m_EkTbOutsideBorder_"+toolbarNumArray[1]+";");eval("menuBorderWidth = m_EkTbMenuBorderWidth_"+toolbarNumArray[1]+";");if(outsideBorder==true){if(tmpLeft-menuBorderWidth<0&&automaticBorder){left=0}else{left=tmpLeft-menuBorderWidth}if(tmpTop-menuBorderWidth<0&&automaticBorder){top=0}else{top=tmpTop-menuBorderWidth}if((left+width==document.body.clientWidth&&tmpLeft-menuBorderWidth<0||left+width+menuBorderWidth==document.body.clientWidth&&tmpLeft-menuBorderWidth>=0)&&automaticBorder){width=document.body.clientWidth-left}else{width+=menuBorderWidth*2}if((top+height==document.body.clientHeight&&tmpTop-menuBorderWidth<0||top+height+menuBorderWidth==document.body.clientHeight&&tmpTop-menuBorderWidth>=0)&&automaticBorder){height=document.body.clientHeight-top}else{height+=menuBorderWidth*2}}else{left=tmpLeft;top=tmpTop}if(IsPlatformMac()){if(IsBrowserSafari){left+=4;top+=6}else{left+=4;top+=14}}if(toolbarNumArray[1]!="AjaxToolBar"&&document.getElementById("EkTbLeftBar_"+toolbarNumArray[1]).parentNode!=document.body){var BodyObj=document.body;var toolObj1=document.getElementById("EkTbLeftBar_"+toolbarNumArray[1]);toolObj1.parentNode.removeChild(toolObj1);var tmpObj1=BodyObj.appendChild(toolObj1);var toolObj2=document.getElementById("EkTbRightBar_"+toolbarNumArray[1]);toolObj2.parentNode.removeChild(toolObj2);var tmpObj2=BodyObj.appendChild(toolObj2);var toolObj3=document.getElementById("EkTbTopBar_"+toolbarNumArray[1]);toolObj3.parentNode.removeChild(toolObj3);var tmpObj3=BodyObj.appendChild(toolObj3);var toolObj4=document.getElementById("EkTbBottomBar_"+toolbarNumArray[1]);toolObj4.parentNode.removeChild(toolObj4);var tmpObj4=BodyObj.appendChild(toolObj4);var toolObj5=document.getElementById("EkTbToolbar_"+toolbarNumArray[1]);toolObj5.parentNode.removeChild(toolObj5);var tmpObj5=BodyObj.appendChild(toolObj5)}document.getElementById("EkTbLeftBar_"+toolbarNumArray[1]).style.top=top+"px";document.getElementById("EkTbLeftBar_"+toolbarNumArray[1]).style.left=left+"px";document.getElementById("EkTbLeftBar_"+toolbarNumArray[1]).style.width=menuBorderWidth+"px";document.getElementById("EkTbLeftBar_"+toolbarNumArray[1]).style.height=height+"px";document.getElementById("EkTbRightBar_"+toolbarNumArray[1]).style.top=top+"px";document.getElementById("EkTbRightBar_"+toolbarNumArray[1]).style.left=left+width-menuBorderWidth+"px";document.getElementById("EkTbRightBar_"+toolbarNumArray[1]).style.width=menuBorderWidth+"px";document.getElementById("EkTbRightBar_"+toolbarNumArray[1]).style.height=height+"px";document.getElementById("EkTbTopBar_"+toolbarNumArray[1]).style.top=top+"px";document.getElementById("EkTbTopBar_"+toolbarNumArray[1]).style.left=left+"px";document.getElementById("EkTbTopBar_"+toolbarNumArray[1]).style.width=width+"px";document.getElementById("EkTbTopBar_"+toolbarNumArray[1]).style.height=menuBorderWidth+"px";document.getElementById("EkTbBottomBar_"+toolbarNumArray[1]).style.top=top+height-menuBorderWidth+"px";document.getElementById("EkTbBottomBar_"+toolbarNumArray[1]).style.left=left+"px";document.getElementById("EkTbBottomBar_"+toolbarNumArray[1]).style.width=width+"px";document.getElementById("EkTbBottomBar_"+toolbarNumArray[1]).style.height=menuBorderWidth+"px";document.getElementById("EkTbLeftBar_"+toolbarNumArray[1]).style.display="";document.getElementById("EkTbRightBar_"+toolbarNumArray[1]).style.display="";document.getElementById("EkTbTopBar_"+toolbarNumArray[1]).style.display="";document.getElementById("EkTbBottomBar_"+toolbarNumArray[1]).style.display=""}function IsBrowserSafari(){if(m_isSafariInit){return m_isSafari}else{var a;var b=new String(navigator.userAgent);b=b.toLowerCase();a=parseInt(b.indexOf("safari"));m_isSafari=0<=a;m_isSafariInit=true;return m_isSafari}}function IsPlatformMac(){if(m_isMacInit){return m_isMac}else{var a;var b=new String(navigator.userAgent);b=b.toLowerCase();a=parseInt(b.indexOf("mac"));m_isMac=0<=a;m_isMacInit=true;return m_isMac}}function EkTbFade(a,b,c,d,e,f,g){if(!m_bEkTbReady)return false;var h=document.getElementById(g);if(e==0){if(!document.all){h.style.MozOpacity=a/100}else{h.filters.alpha.opacity=a}if(a>=0&&c<0||a<99&&c>0){a+=c;if(a>99){a=99}setTimeout("EkTbFade("+a+","+b+","+c+","+d+","+e+",'"+f+"','"+g+"')",b)}else{c=0-c;a+=c;if(f.toLowerCase()=="cycle"){setTimeout("EkTbFade("+a+","+b+","+c+","+d+","+e+",'"+f+"','"+g+"')",d)}}}else{var i=e;e=0;setTimeout("EkTbFade("+a+","+b+","+c+","+d+","+e+",'"+f+"','"+g+"')",i)}}function EkTbWebMenuPopUpWindow(a,b,c,d,e,f){a=a.replace(/&amp;/g,"&").replace(/&/g,"&");if(!m_bEkTbReady)return false;if(c>screen.width){c=screen.width}if(d>screen.height){d=screen.height}var g="toolbar=0,location=0,directories=0,status="+f+",menubar=0,scrollbars="+e+",resizable="+f+",width="+c+",height="+d;var h=window.open(a,b,g);return h}function addEkTbLoadEvent(){var a=window.onload;window.onload=function(){if(typeof a=="function"){a()}setTimeout("m_bEkTbReady = true;",500)}}function GetPreviewURL(){var a=self.location.href;var b=a.split("?");if(b.length>1){a=a+"&cmsMode=Preview"}else{a=a+"?cmsMode=Preview"}return a}var m_EkTbTimeout_AjaxToolBar=null;var m_EkTbAutomaticOutsideBorder_AjaxToolBar=true;var m_EkTbOutsideBorder_AjaxToolBar=true;var m_EkTbMenuOffDelay_AjaxToolBar=500;var m_EkTbMenuBorderWidth_AjaxToolBar=3;var m_EkTbStopAtRoot=0;var m_EkTbStopAtCss=1;var m_EkTbStopAtOffset=2;var m_EkTbLastObj;var m_bEkTbReady;if(m_bEkTbReady!==true){m_bEkTbReady=false}if(typeof $ektron!=="undefined"){$ektron().ready(function(){m_bEkTbReady=true})}addEkTbLoadEvent();var m_isMac=false;var m_isMacInit=false;var m_isSafari=false;var m_isSafariInit=false;if(typeof $ektron!=="undefined"){$ektron().ready(function(){$ektron(document).bind("click",function(a){$ektron(".EktronEditorsMenu").slideUp("fast")})})}
