var screenHeight=window.screen.availHeight,screenWidth=window.screen.availWidth,colorDepth=window.screen.colorDepth,timeNow=new Date,referrer=escape(document.referrer),windows,mac,linux,ie,op,moz,misc,browsercode,browsername,browserversion,operatingsys,dom,ienew,ie4,ie5,ie6,moz_rv,moz_rv_sub,ie5mac,ie5xwin,opnu,op4,op5,op6,op7,saf,konq,appName,appVersion,userAgent,appname=navigator.appName;appVersion=navigator.appVersion;userAgent=navigator.userAgent.toLowerCase();
var title=document.title,checktoggle=1,DOM="default";windows=appVersion.indexOf("Win")!=-1;mac=appVersion.indexOf("Mac")!=-1;linux=appVersion.indexOf("Linux")!=-1;dom=document.layers?false:document.getElementById?document.getElementById:false;if(document.getElementById)DOM="default";else if(document.layers)DOM="NS4";else if(document.all)DOM="IE4";misc=appVersion.substring(0,1)<4;op=userAgent.indexOf("opera")!=-1;moz=userAgent.indexOf("gecko")!=-1;ie=document.all&&!op;
saf=userAgent.indexOf("safari")!=-1||navigator.vendor=="Apple Computer, Inc.";konq=userAgent.indexOf("konqueror")!=-1;
if(op){op_pos=userAgent.indexOf("opera");opnu=userAgent.substr(op_pos+6,4);op5=opnu.substring(0,1)==5;op6=opnu.substring(0,1)==6;op7=opnu.substring(0,1)==7}else if(moz){rv_pos=userAgent.indexOf("rv");moz_rv=userAgent.substr(rv_pos+3,3);moz_rv_sub=userAgent.substr(rv_pos+7,1);if(moz_rv_sub==" "||isNaN(moz_rv_sub))moz_rv_sub="";moz_rv+=moz_rv_sub}else if(ie){ie_pos=userAgent.indexOf("msie");ienu=userAgent.substr(ie_pos+5,3);ie4=!dom;ie5=ienu.substring(0,1)==5;ie6=ienu.substring(0,1)==6}
if(konq){browsercode="KO";browserversion=appVersion;browsername="Knoqueror"}else if(saf){browsercode="SF";browserversion=appVersion;browsername="Safari"}else if(op){browsercode="OP";browserversion=op5?"5":op6?"6":op7?"7":appVersion;browsername="Opera"}else if(moz){browsercode="MO";browserversion=appVersion;browsername="Mozilla"}else if(ie){browsercode="IE";browserversion=ie4?"4":ie5?"5":ie6?"6":appVersion;browsername="Internet Explorer"}operatingsys=windows?"Windows":linux?"Linux":mac?"Mac":"Unkown";
function doRand(){var a;now=new Date;a=now.getSeconds();a+=1;return a}function getCookie(a){var c=document.cookie;a=c.indexOf(a+"=");if(a==-1)return null;a=c.indexOf("=",a)+1;var b=c.indexOf(";",a);if(b==-1)b=c.length;return unescape(c.substring(a,b))}function deleteCookie(a){document.cookie=a+"=; expires=Thu, 01-Jan-70 00:00:01 GMT; path=/"}
function browserObject(a){if(DOM=="default")return document.getElementById(a);else if(DOM=="NS4")return document.layers[a];else if(DOM=="IE4")return document.all[a]}function switchDisplay(a){if(result=browserObject(a))result.style.display=result.style.display=="none"?"":"none";else alert("Invalid Display Object: "+a+"\nPlease make sure that all correct display objects are on the page")}
function displayObject(a){if(result=browserObject(a))result.style.display="";else alert("Invalid Display Object: "+a+"\nPlease make sure that all correct display objects are on the page")}function hideObject(a){if(result=browserObject(a))result.style.display="none";else alert("Invalid Display Object: "+a+"\nPlease make sure that all correct display objects are on the page")}
function htmlize(a){a=new String(a);a=a.replace(/\&/g,"&amp;");a=a.replace(/\</g,"&lt;");a=a.replace(/\>/g,"&gt;");a=a.replace(/\"/g,"&quot;");return a=a.replace(/\n/g,"<br/>\n")}function writeMessage(a){if(browsercode=="OP")window.parent.contentframe.writeToDiv(a);else browsercode=="SF"?writeToDivSaf(a):writeToDoc(a)}
function writeToDoc(a){window.parent.contentframe.window.document.write(a);if(typeof scrollBy!="undefined")window.parent.contentframe.window.scrollBy(0,6E3);else typeof scroll!="undefined"&&window.parent.contentframe.window.scrollBy(0,6E3)}
function clearDoc(){if(browsercode=="OP")window.parent.contentframe.clearDiv();else{window.parent.contentframe.window.document.close();window.parent.contentframe.window.document.open();window.parent.contentframe.window.document.clear();window.parent.contentframe.window.document.write("")}}function writeToDiv(a){divobj=browserObject("buffer");divobj.innerHTML+=a;if(typeof scrollBy!="undefined")window.scrollBy(0,6E3);else typeof scroll!="undefined"&&window.scrollBy(0,6E3)}
function writeToDivSaf(a){divobj=parent.contentframe.document.getElementById("buffer");divobj.innerHTML+=a;if(typeof scrollBy!="undefined")window.scrollBy(0,6E3);else typeof scroll!="undefined"&&window.scrollBy(0,6E3)}function clearDiv(){divobj=browserObject("buffer");divobj.innerHTML=""}function addBookmark(a,c){if(window.sidebar)window.sidebar.addPanel(a,c,"");else if(document.all)window.external.AddFavorite(c,a);else if(window.opera&&window.print)return true}
function popupInfoWindow(a){screen_width=screen.width;screen_height=screen.height;widthm=(screen_width-400)/2;heightm=(screen_height-500)/2;window.open(a,"infowindow"+doRand(),"toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=400,height=500,left="+widthm+",top="+heightm)}function jumpLanguage(a){languageid=a.options[[a.selectedIndex]].value;window.location.href="index.php?languageid="+languageid}var xmlhttp,xmlaction="";
function loadXMLHTTPRequest(a){if(window.XMLHttpRequest){xmlhttp=new XMLHttpRequest;xmlhttp.onreadystatechange=processStatusChange;xmlhttp.open("GET",a,true);xmlhttp.send(null)}else if(window.ActiveXObject)if(xmlhttp=new ActiveXObject("Microsoft.XMLHTTP")){xmlhttp.onreadystatechange=processStatusChange;xmlhttp.open("GET",a,true);xmlhttp.send()}}
function processStatusChange(){if(xmlhttp.readyState==4)if(xmlhttp.status==200)if(xmlaction=="irsfetch")if((irsObject=browserObject("irsui"))&&""!=xmlhttp.responseText)irsObject.innerHTML=xmlhttp.responseText}var irsContents="",irsFailed=false;
function startIRSTimer(){if(document.submitticket.message.value!=irsContents&&document.submitticket.message.value!=""){try{if(!irsFailed){displayObject("irsui");xmlaction="irsfetch";loadXMLHTTPRequest(swiftpath+"index.php?_m=knowledgebase&_a=irsfetch&randno="+doRand()+"&query="+encodeURIComponent(document.submitticket.message.value))}}catch(a){hideObject("irsui");irsFailed=true}irsContents=document.submitticket.message.value}setTimeout("startIRSTimer();",2E3)}var limitTextOldBorders=[];
function limitText(a,c){var b=document.getElementById(a);if(b.currentStyle)limitTextOldBorders[a]||(limitTextOldBorders[a]=b.currentStyle.borderWidth+" "+b.currentStyle.borderColor+" "+b.currentStyle.borderStyle);if(b.value.length>=c){if(b.value.length>c)b.value=b.value.substring(0,c);b.style.border="1px solid #dd7700"}else b.style.border=b.currentStyle?limitTextOldBorders[a]:""};

