var agt=navigator.userAgent.toLowerCase();var is_major=parseInt(navigator.appVersion);var is_minor=parseFloat(navigator.appVersion);var is_nav=((agt.indexOf('mozilla')!=-1)&&(agt.indexOf('spoofer')==-1)&&(agt.indexOf('compatible')==-1)&&(agt.indexOf('opera')==-1)&&(agt.indexOf('webtv')==-1)&&(agt.indexOf('hotjava')==-1));var is_nav2=(is_nav&&(is_major==2));var is_nav3=(is_nav&&(is_major==3));var is_nav4=(is_nav&&(is_major==4));var is_nav4up=(is_nav&&(is_major>=4));var is_navonly=(is_nav&&((agt.indexOf(";nav")!=-1)||(agt.indexOf("; nav")!=-1)));var is_nav6=(is_nav&&(is_major==5));var is_nav6up=(is_nav&&(is_major>=5));var is_gecko=(agt.indexOf('gecko')!=-1);var is_ie=((agt.indexOf("msie")!=-1)&&(agt.indexOf("opera")==-1));var is_ie3=(is_ie&&(is_major<4));var is_ie4=(is_ie&&(is_major==4)&&(agt.indexOf("msie 4")!=-1));var is_ie4up=(is_ie&&(is_major>=4));var is_ie5=(is_ie&&(is_major==4)&&(agt.indexOf("msie 5.0")!=-1));var is_ie5_5=(is_ie&&(is_major==4)&&(agt.indexOf("msie 5.5")!=-1));var is_ie5up=(is_ie&&!is_ie3&&!is_ie4);var is_ie5_5up=(is_ie&&!is_ie3&&!is_ie4&&!is_ie5);var is_ie6=(is_ie&&(is_major==4)&&(agt.indexOf("msie 6.")!=-1));var is_ie6up=(is_ie&&!is_ie3&&!is_ie4&&!is_ie5&&!is_ie5_5);var is_aol=(agt.indexOf("aol")!=-1);var is_aol3=(is_aol&&is_ie3);var is_aol4=(is_aol&&is_ie4);var is_aol5=(agt.indexOf("aol 5")!=-1);var is_aol6=(agt.indexOf("aol 6")!=-1);var is_opera=(agt.indexOf("opera")!=-1);var is_opera2=(agt.indexOf("opera 2")!=-1||agt.indexOf("opera/2")!=-1);var is_opera3=(agt.indexOf("opera 3")!=-1||agt.indexOf("opera/3")!=-1);var is_opera4=(agt.indexOf("opera 4")!=-1||agt.indexOf("opera/4")!=-1);var is_opera5=(agt.indexOf("opera 5")!=-1||agt.indexOf("opera/5")!=-1);var is_opera5up=(is_opera&&!is_opera2&&!is_opera3&&!is_opera4);var is_webtv=(agt.indexOf("webtv")!=-1);var is_TVNavigator=((agt.indexOf("navio")!=-1)||(agt.indexOf("navio_aoltv")!=-1));var is_AOLTV=is_TVNavigator;var is_hotjava=(agt.indexOf("hotjava")!=-1);var is_hotjava3=(is_hotjava&&(is_major==3));var is_hotjava3up=(is_hotjava&&(is_major>=3));var is_js;if(is_nav2||is_ie3)is_js=1.0;else if(is_nav3)is_js=1.1;else if(is_opera5up)is_js=1.3;else if(is_opera)is_js=1.1;else if((is_nav4&&(is_minor<=4.05))||is_ie4)is_js=1.2;else if((is_nav4&&(is_minor>4.05))||is_ie5)is_js=1.3;else if(is_hotjava3up)is_js=1.4;else if(is_nav6||is_gecko)is_js=1.5;else if(is_nav6up)is_js=1.5;else if(is_ie5up)is_js=1.3
else is_js=0.0;var is_win=((agt.indexOf("win")!=-1)||(agt.indexOf("16bit")!=-1));var is_win95=((agt.indexOf("win95")!=-1)||(agt.indexOf("windows 95")!=-1));var is_win16=((agt.indexOf("win16")!=-1)||(agt.indexOf("16bit")!=-1)||(agt.indexOf("windows 3.1")!=-1)||(agt.indexOf("windows 16-bit")!=-1));var is_win31=((agt.indexOf("windows 3.1")!=-1)||(agt.indexOf("win16")!=-1)||(agt.indexOf("windows 16-bit")!=-1));var is_winme=((agt.indexOf("win 9x 4.90")!=-1));var is_win2k=((agt.indexOf("windows nt 5.0")!=-1));var is_win98=((agt.indexOf("win98")!=-1)||(agt.indexOf("windows 98")!=-1));var is_winnt=((agt.indexOf("winnt")!=-1)||(agt.indexOf("windows nt")!=-1));var is_win32=(is_win95||is_winnt||is_win98||((is_major>=4)&&(navigator.platform=="Win32"))||(agt.indexOf("win32")!=-1)||(agt.indexOf("32bit")!=-1));var is_os2=((agt.indexOf("os/2")!=-1)||(navigator.appVersion.indexOf("OS/2")!=-1)||(agt.indexOf("ibm-webexplorer")!=-1));var is_mac=(agt.indexOf("mac")!=-1);if(is_mac&&is_ie5up)is_js=1.4;var is_mac68k=(is_mac&&((agt.indexOf("68k")!=-1)||(agt.indexOf("68000")!=-1)));var is_macppc=(is_mac&&((agt.indexOf("ppc")!=-1)||(agt.indexOf("powerpc")!=-1)));var is_sun=(agt.indexOf("sunos")!=-1);var is_sun4=(agt.indexOf("sunos 4")!=-1);var is_sun5=(agt.indexOf("sunos 5")!=-1);var is_suni86=(is_sun&&(agt.indexOf("i86")!=-1));var is_irix=(agt.indexOf("irix")!=-1);var is_irix5=(agt.indexOf("irix 5")!=-1);var is_irix6=((agt.indexOf("irix 6")!=-1)||(agt.indexOf("irix6")!=-1));var is_hpux=(agt.indexOf("hp-ux")!=-1);var is_hpux9=(is_hpux&&(agt.indexOf("09.")!=-1));var is_hpux10=(is_hpux&&(agt.indexOf("10.")!=-1));var is_aix=(agt.indexOf("aix")!=-1);var is_aix1=(agt.indexOf("aix 1")!=-1);var is_aix2=(agt.indexOf("aix 2")!=-1);var is_aix3=(agt.indexOf("aix 3")!=-1);var is_aix4=(agt.indexOf("aix 4")!=-1);var is_linux=(agt.indexOf("inux")!=-1);var is_sco=(agt.indexOf("sco")!=-1)||(agt.indexOf("unix_sv")!=-1);var is_unixware=(agt.indexOf("unix_system_v")!=-1);var is_mpras=(agt.indexOf("ncr")!=-1);var is_reliant=(agt.indexOf("reliantunix")!=-1);var is_dec=((agt.indexOf("dec")!=-1)||(agt.indexOf("osf1")!=-1)||(agt.indexOf("dec_alpha")!=-1)||(agt.indexOf("alphaserver")!=-1)||(agt.indexOf("ultrix")!=-1)||(agt.indexOf("alphastation")!=-1));var is_sinix=(agt.indexOf("sinix")!=-1);var is_freebsd=(agt.indexOf("freebsd")!=-1);var is_bsd=(agt.indexOf("bsd")!=-1);var is_unix=((agt.indexOf("x11")!=-1)||is_sun||is_irix||is_hpux||is_sco||is_unixware||is_mpras||is_reliant||is_dec||is_sinix||is_aix||is_linux||is_bsd||is_freebsd);var is_vms=((agt.indexOf("vax")!=-1)||(agt.indexOf("openvms")!=-1));Array.prototype.containsValue=function(valueToCheck){for(var i=0;i<this.length;i++){if(this[i]==valueToCheck)return true;}
return false;}
function Xajax(){this.DebugMessage=function(text){if(text.length>1000)text=text.substr(0,1000)+"...\n[long response]\n...";try{if(this.debugWindow==undefined||this.debugWindow.closed==true){this.debugWindow=window.open('about:blank','xajax-debug','width=800,height=600,scrollbars=1,resizable,status');this.debugWindow.document.write('<html><head><title>Xajax debug output</title></head><body><h2>Xajax debug output</h2><div id="debugTag"></div></body></html>');}
text=text.replace(/&/g,"&amp;")
text=text.replace(/</g,"&lt;")
text=text.replace(/>/g,"&gt;")
debugTag=this.debugWindow.document.getElementById('debugTag');debugTag.innerHTML=('<b>'+(new Date()).toString()+'</b>: '+text+'<hr/>')+debugTag.innerHTML;}catch(e){alert("Xajax Debug:\n "+text);}};this.workId='xajaxWork'+new Date().getTime();this.depth=0;this.responseErrorsForAlert=["400","401","402","403","404","500","501","502","503"];this.getRequestObject=function(){if(xajaxDebug)this.DebugMessage("Initializing Request Object..");var req=null;if(typeof XMLHttpRequest!="undefined")
req=new XMLHttpRequest();if(!req&&typeof ActiveXObject!="undefined"){try{req=new ActiveXObject("Msxml2.XMLHTTP");}
catch(e){try{req=new ActiveXObject("Microsoft.XMLHTTP");}
catch(e2){try{req=new ActiveXObject("Msxml2.XMLHTTP.4.0");}
catch(e3){req=null;}}}}
if(!req&&window.createRequest)
req=window.createRequest();if(!req)this.DebugMessage("Request Object Instantiation failed.");return req;}
this.$=function(sId){if(!sId){return null;}
var returnObj=document.getElementById(sId);if(!returnObj&&document.all){returnObj=document.all[sId];}
if(xajaxDebug&&!returnObj&&sId!=this.workId){this.DebugMessage("Element with the id \""+sId+"\" not found.");}
return returnObj;}
this.include=function(sFileName){var objHead=document.getElementsByTagName('head');var objScript=document.createElement('script');objScript.type='text/javascript';objScript.src=sFileName;objHead[0].appendChild(objScript);}
this.stripOnPrefix=function(sEventName){sEventName=sEventName.toLowerCase();if(sEventName.indexOf('on')==0){sEventName=sEventName.replace(/on/,'');}
return sEventName;}
this.addOnPrefix=function(sEventName){sEventName=sEventName.toLowerCase();if(sEventName.indexOf('on')!=0){sEventName='on'+sEventName;}
return sEventName;}
this.addHandler=function(sElementId,sEvent,sFunctionName){if(window.addEventListener){sEvent=this.stripOnPrefix(sEvent);eval("this.$('"+sElementId+"').addEventListener('"+sEvent+"',"+sFunctionName+",false);");}
else{sAltEvent=this.addOnPrefix(sEvent);eval("this.$('"+sElementId+"').attachEvent('"+sAltEvent+"',"+sFunctionName+",false);");}}
this.removeHandler=function(sElementId,sEvent,sFunctionName){if(window.addEventListener){sEvent=this.stripOnPrefix(sEvent);eval("this.$('"+sElementId+"').removeEventListener('"+sEvent+"',"+sFunctionName+",false);");}
else{sAltEvent=this.addOnPrefix(sEvent);eval("this.$('"+sElementId+"').detachEvent('"+sAltEvent+"',"+sFunctionName+",false);");}}
this.create=function(sParentId,sTag,sId){var objParent=this.$(sParentId);objElement=document.createElement(sTag);objElement.setAttribute('id',sId);if(objParent)
objParent.appendChild(objElement);}
this.insert=function(sBeforeId,sTag,sId){var objSibling=this.$(sBeforeId);objElement=document.createElement(sTag);objElement.setAttribute('id',sId);objSibling.parentNode.insertBefore(objElement,objSibling);}
this.insertAfter=function(sAfterId,sTag,sId){var objSibling=this.$(sAfterId);objElement=document.createElement(sTag);objElement.setAttribute('id',sId);objSibling.parentNode.insertBefore(objElement,objSibling.nextSibling);}
this.getInput=function(sType,sName,sId){var Obj;if(!window.addEventListener){Obj=document.createElement('<input type="'+sType+'" id="'+sId+'" name="'+sName+'">');}
else{Obj=document.createElement('input');Obj.setAttribute('type',sType);Obj.setAttribute('name',sName);Obj.setAttribute('id',sId);}
return Obj;}
this.createInput=function(sParentId,sType,sName,sId){var objParent=this.$(sParentId);var objElement=this.getInput(sType,sName,sId);if(objParent&&objElement)
objParent.appendChild(objElement);}
this.insertInput=function(sBeforeId,sType,sName,sId){var objSibling=this.$(sBeforeId);var objElement=this.getInput(sType,sName,sId);if(objElement&&objSibling&&objSibling.parentNode)
objSibling.parentNode.insertBefore(objElement,objSibling);}
this.insertInputAfter=function(sAfterId,sType,sName,sId){var objSibling=this.$(sAfterId);var objElement=this.getInput(sType,sName,sId);if(objElement&&objSibling&&objSibling.parentNode){objSibling.parentNode.insertBefore(objElement,objSibling.nextSibling);}}
this.remove=function(sId){objElement=this.$(sId);if(objElement&&objElement.parentNode&&objElement.parentNode.removeChild){objElement.parentNode.removeChild(objElement);}}
this.replace=function(sId,sAttribute,sSearch,sReplace){var bFunction=false;if(sAttribute=="innerHTML")
sSearch=this.getBrowserHTML(sSearch);eval("var txt=this.$('"+sId+"')."+sAttribute);if(typeof txt=="function"){txt=txt.toString();bFunction=true;}
if(txt.indexOf(sSearch)>-1){var newTxt='';while(txt.indexOf(sSearch)>-1){x=txt.indexOf(sSearch)+sSearch.length+1;newTxt+=txt.substr(0,x).replace(sSearch,sReplace);txt=txt.substr(x,txt.length-x);}
newTxt+=txt;if(bFunction){eval('this.$("'+sId+'").'+sAttribute+'=newTxt;');}
else if(this.willChange(sId,sAttribute,newTxt)){eval('this.$("'+sId+'").'+sAttribute+'=newTxt;');}}}
this.getFormValues=function(frm){var objForm;var submitDisabledElements=false;if(arguments.length>1&&arguments[1]==true)
submitDisabledElements=true;var prefix="";if(arguments.length>2)
prefix=arguments[2];if(typeof(frm)=="string")
objForm=this.$(frm);else
objForm=frm;var sXml="<xjxquery><q>";if(objForm&&objForm.tagName=='FORM'){var formElements=objForm.elements;for(var i=0;i<formElements.length;i++){if(!formElements[i].name)
continue;if(formElements[i].name.substring(0,prefix.length)!=prefix)
continue;if(formElements[i].type&&(formElements[i].type=='radio'||formElements[i].type=='checkbox')&&formElements[i].checked==false)
continue;if(formElements[i].disabled&&formElements[i].disabled==true&&submitDisabledElements==false)
continue;var name=formElements[i].name;if(name){if(sXml!='<xjxquery><q>')
sXml+='&';if(formElements[i].type=='select-multiple'){for(var j=0;j<formElements[i].length;j++){if(formElements[i].options[j].selected==true)
sXml+=name+"="+encodeURIComponent(formElements[i].options[j].value)+"&";}}
else{sXml+=name+"="+encodeURIComponent(formElements[i].value);}}}}
sXml+="</q></xjxquery>";return sXml;}
this.objectToXML=function(obj){var sXml="<xjxobj>";for(i in obj){try{if(i=='constructor')
continue;if(obj[i]&&typeof(obj[i])=='function')
continue;var key=i;var value=obj[i];if(value&&typeof(value)=="object"&&this.depth<=50){this.depth++;value=this.objectToXML(value);this.depth--;}
sXml+="<e><k>"+key+"</k><v>"+value+"</v></e>";}
catch(e){if(xajaxDebug)this.DebugMessage(e.name+": "+e.message);}}
sXml+="</xjxobj>";return sXml;}
this._nodeToObject=function(node){if(node.nodeName=='#cdata-section'){var data="";for(var j=0;j<node.parentNode.childNodes.length;j++){data+=node.parentNode.childNodes[j].data;}
return data;}
else if(node.nodeName=='xjxobj'){var data=new Array();for(var j=0;j<node.childNodes.length;j++){var child=node.childNodes[j];var key;var value;if(child.nodeName=='e'){for(var k=0;k<child.childNodes.length;k++){if(child.childNodes[k].nodeName=='k'){key=child.childNodes[k].firstChild.data;}
else if(child.childNodes[k].nodeName=='v'){value=this._nodeToObject(child.childNodes[k].firstChild);}}
if(key!=null&&value!=null){data[key]=value;key=value=null;}}}
return data;}}
this.loadingFunction=function(){};this.doneLoadingFunction=function(){};var loadingTimeout;this.call=function(sFunction,aArgs,sRequestType){var i,r,postData;if(document.body&&xajaxWaitCursor)
document.body.style.cursor='wait';if(xajaxStatusMessages==true)window.status='Sending Request...';clearTimeout(loadingTimeout);loadingTimeout=setTimeout("xajax.loadingFunction();",400);if(xajaxDebug)this.DebugMessage("Starting xajax...");if(sRequestType==null){var xajaxRequestType=xajaxDefinedPost;}
else{var xajaxRequestType=sRequestType;}
var uri=xajaxRequestUri;var value;switch(xajaxRequestType){case xajaxDefinedGet:{var uriGet=uri.indexOf("?")==-1?"?xajax="+encodeURIComponent(sFunction):"&xajax="+encodeURIComponent(sFunction);if(aArgs){for(i=0;i<aArgs.length;i++){value=aArgs[i];if(typeof(value)=="object")
value=this.objectToXML(value);uriGet+="&xajaxargs[]="+encodeURIComponent(value);}}
uriGet+="&xajaxr="+new Date().getTime();uri+=uriGet;postData=null;}break;case xajaxDefinedPost:{postData="xajax="+encodeURIComponent(sFunction);postData+="&xajaxr="+new Date().getTime();if(aArgs){for(i=0;i<aArgs.length;i++){value=aArgs[i];if(typeof(value)=="object")
value=this.objectToXML(value);postData=postData+"&xajaxargs[]="+encodeURIComponent(value);}}}break;default:alert("Illegal request type: "+xajaxRequestType);return false;break;}
r=this.getRequestObject();if(!r)return false;r.open(xajaxRequestType==xajaxDefinedGet?"GET":"POST",uri,true);if(xajaxRequestType==xajaxDefinedPost){try{r.setRequestHeader("Method","POST "+uri+" HTTP/1.1");r.setRequestHeader("Content-Type","application/x-www-form-urlencoded");}
catch(e){alert("Your browser does not appear to  support asynchronous requests using POST.");return false;}}
r.onreadystatechange=function(){if(r.readyState!=4)
return;if(r.status==200){if(xajaxDebug)xajax.DebugMessage("Received:\n"+r.responseText);if(r.responseXML&&r.responseXML.documentElement)
xajax.processResponse(r.responseXML);else{var errorString="Error: the XML response that was returned from the server is invalid.";errorString+="\nReceived:\n"+r.responseText;trimmedResponseText=r.responseText.replace(/^\s+/g,"");trimmedResponseText=trimmedResponseText.replace(/\s+$/g,"");if(trimmedResponseText!=r.responseText)
errorString+="\nYou have whitespace in your response.";alert(errorString);document.body.style.cursor='default';if(xajaxStatusMessages==true)window.status='Invalid XML response error';}}
else{if(xajax.responseErrorsForAlert.containsValue(r.status)){var errorString="Error: the server returned the following HTTP status: "+r.status;errorString+="\nReceived:\n"+r.responseText;alert(errorString);}
document.body.style.cursor='default';if(xajaxStatusMessages==true)window.status='Invalid XML response error';}
delete r;r=null;}
if(xajaxDebug)this.DebugMessage("Calling "+sFunction+" uri="+uri+" (post:"+postData+")");r.send(postData);if(xajaxStatusMessages==true)window.status='Waiting for data...';delete r;return true;}
this.getBrowserHTML=function(html){tmpXajax=this.$(this.workId);if(!tmpXajax){tmpXajax=document.createElement("div");tmpXajax.setAttribute('id',this.workId);tmpXajax.style.display="none";tmpXajax.style.visibility="hidden";document.body.appendChild(tmpXajax);}
tmpXajax.innerHTML=html;var browserHTML=tmpXajax.innerHTML;tmpXajax.innerHTML='';return browserHTML;}
this.willChange=function(element,attribute,newData){if(!document.body){return true;}
if(attribute=="innerHTML"){newData=this.getBrowserHTML(newData);}
elementObject=this.$(element);if(elementObject){var oldData;eval("oldData=this.$('"+element+"')."+attribute);if(newData!==oldData)
return true;}
return false;}
this.viewSource=function(){return"<html>"+document.getElementsByTagName("HTML")[0].innerHTML+"</html>";}
this.processResponse=function(xml){clearTimeout(loadingTimeout);this.doneLoadingFunction();if(xajaxStatusMessages==true)window.status='Processing...';var tmpXajax=null;xml=xml.documentElement;if(xml==null)
return;var skipCommands=0;for(var i=0;i<xml.childNodes.length;i++){if(skipCommands>0){skipCommands--;continue;}
if(xml.childNodes[i].nodeName=="cmd"){var cmd;var id;var property;var data;var search;var type;var before;var objElement=null;for(var j=0;j<xml.childNodes[i].attributes.length;j++){if(xml.childNodes[i].attributes[j].name=="n"){cmd=xml.childNodes[i].attributes[j].value;}
else if(xml.childNodes[i].attributes[j].name=="t"){id=xml.childNodes[i].attributes[j].value;}
else if(xml.childNodes[i].attributes[j].name=="p"){property=xml.childNodes[i].attributes[j].value;}
else if(xml.childNodes[i].attributes[j].name=="c"){type=xml.childNodes[i].attributes[j].value;}}
if(xml.childNodes[i].childNodes.length>1&&xml.childNodes[i].firstChild.nodeName=="#cdata-section"){data="";for(var j=0;j<xml.childNodes[i].childNodes.length;j++){data+=xml.childNodes[i].childNodes[j].data;}}
else if(xml.childNodes[i].firstChild&&xml.childNodes[i].firstChild.nodeName=='xjxobj'){data=this._nodeToObject(xml.childNodes[i].firstChild);objElement="XJX_SKIP";}
else if(xml.childNodes[i].childNodes.length>1){for(var j=0;j<xml.childNodes[i].childNodes.length;j++){if(xml.childNodes[i].childNodes[j].childNodes.length>1&&xml.childNodes[i].childNodes[j].firstChild.nodeName=="#cdata-section"){var internalData="";for(var k=0;k<xml.childNodes[i].childNodes[j].childNodes.length;k++){internalData+=xml.childNodes[i].childNodes[j].childNodes[k].nodeValue;}}else{var internalData=xml.childNodes[i].childNodes[j].firstChild.nodeValue;}
if(xml.childNodes[i].childNodes[j].nodeName=="s"){search=internalData;}
if(xml.childNodes[i].childNodes[j].nodeName=="r"){data=internalData;}}}
else if(xml.childNodes[i].firstChild)
data=xml.childNodes[i].firstChild.nodeValue;else
data="";if(objElement!="XJX_SKIP")objElement=this.$(id);var cmdFullname;try{if(cmd=="cc"){cmdFullname="addConfirmCommands";var confirmResult=confirm(data);if(!confirmResult){skipCommands=id;}}
if(cmd=="al"){cmdFullname="addAlert";alert(data);}
else if(cmd=="js"){cmdFullname="addScript/addRedirect";eval(data);}
else if(cmd=="jc"){cmdFullname="addScriptCall";var scr=id+'(';if(data[0]!=null){scr+='data[0]';for(var l=1;l<data.length;l++){scr+=',data['+l+']';}}
scr+=');';eval(scr);}
else if(cmd=="in"){cmdFullname="addIncludeScript";this.include(data);}
else if(cmd=="as"){cmdFullname="addAssign/addClear";if(this.willChange(id,property,data)){eval("objElement."+property+"=data;");}}
else if(cmd=="ap"){cmdFullname="addAppend";eval("objElement."+property+"+=data;");}
else if(cmd=="pp"){cmdFullname="addPrepend";eval("objElement."+property+"=data+objElement."+property);}
else if(cmd=="rp"){cmdFullname="addReplace";this.replace(id,property,search,data)}
else if(cmd=="rm"){cmdFullname="addRemove";this.remove(id);}
else if(cmd=="ce"){cmdFullname="addCreate";this.create(id,data,property);}
else if(cmd=="ie"){cmdFullname="addInsert";this.insert(id,data,property);}
else if(cmd=="ia"){cmdFullname="addInsertAfter";this.insertAfter(id,data,property);}
else if(cmd=="ci"){cmdFullname="addCreateInput";this.createInput(id,type,data,property);}
else if(cmd=="ii"){cmdFullname="addInsertInput";this.insertInput(id,type,data,property);}
else if(cmd=="iia"){cmdFullname="addInsertInputAfter";this.insertInputAfter(id,type,data,property);}
else if(cmd=="ev"){cmdFullname="addEvent";property=this.addOnPrefix(property);eval("this.$('"+id+"')."+property+"= function(){"+data+";}");}
else if(cmd=="ah"){cmdFullname="addHandler";this.addHandler(id,property,data);}
else if(cmd=="rh"){cmdFullname="addRemoveHandler";this.removeHandler(id,property,data);}}
catch(e){if(xajaxDebug)
alert("While trying to '"+cmdFullname+"' (command number "+i+"), the following error occured:\n"+e.name+": "+e.message+"\n"+(id&&!objElement?"Object with id='"+id+"' wasn't found.\n":""));}
delete objElement;delete cmd;delete cmdFullname;delete id;delete property;delete search;delete data;delete type;delete before;delete internalData;delete j;delete k;}}
delete xml;delete i;document.body.style.cursor='default';if(xajaxStatusMessages==true)window.status='Done';}}
var xajax=new Xajax();xajaxLoaded=true;var arrayPageSize;var arrayPageScroll;var cbGlobal,cbTag,taglist;var activemenu="",activesearchmenu="search01",activehintid=-1,activeDrag=0,dragObj,dragX,dragY,resetWeb,hoverObj;var lastScrollTop=0,lastScrollLeft=0;var searchResetHTML="<input type=radio name=searchtype id=op1 class='searchOp' value=0 checked/><label for=op1 class='searchOp'>&nbsp;Címke keresés</label>&nbsp;&nbsp;<input type=radio name=searchtype id=op2 class='searchOp' value=1/><label for=op2 class='searchOp'>&nbsp;Felhasználó keresés</label>&nbsp;&nbsp;<input type=radio name=searchtype id=op3 class='searchOp' value=3/><label for=op3 class='searchOp' onmousemove=\"showhint(100,true,'Keresés a weboldalak közt címük alapján.&nbsp;<br><b>Írj be egy szótöredéket</b>');\" onmouseout=\"soff();\">&nbsp;Weboldal cím</label>";var searchGoogleHTML="<input type=checkbox id=op1 class='searchOp'/><label for=op1 class='searchOp'>&nbsp;Csak magyar oldalak</label>&nbsp;&nbsp;&nbsp;&nbsp;<input type=checkbox id=op2 class='searchOp'/><label for=op2 class='searchOp'>&nbsp;Google csoportok közt</label>";var searchIMDbHTML="<div class='right'><label for=op1 class='searchOp'>Ugrás azonnal az első találatra&nbsp;&nbsp;</label><input type=checkbox id=op1 class='searchOp' checked/></div>";var searchWikipediaHTML="<div class=left><input type=checkbox id=op1 class='searchOp'/><label for=op1 class='searchOp'>&nbsp;Csak magyar találatok</label></div><div class=right><label for=op2 class='searchOp'>Ugrás azonnal az első találatra&nbsp;&nbsp;</label><input type=checkbox id=op2 class='searchOp' checked/></div>";var tipp=new Array("<b>Kereső váltás:</b><br>shift + szóköz","Nem működik"," felhasználói címke beállítása keresési feltételnek&nbsp;<br>(dinamikus szűrés)"," címke hozzáadása a keresési feltételekhez&nbsp;<br>(dinamikus szűrés)"," felhasználói címke beállítása keresési feltételnek&nbsp;<br>(dinamikus szűrés)"," címke hozzáadása a keresési feltételekhez&nbsp;<br>(dinamikus szűrés)","Weboldal előnézet-ablak megnyitása/bezárása","Bezár","Megnyitás teljes ablakban","Belső RSS olvasó megnyitása/bezárása","publikussá tesz","kedvenc státusz kikapcsolása","Mentés előtt a weboldalon kijelölt szövegrész&nbsp;<br>automatikusan bekerül ide.&nbsp;&nbsp;<i>próbáld ki</i> :)");var slide=new Array(1,2,2,3,5,8,11,17,26,38,58,86,130,195,292,438,657,985,1478,2217);var activeHintXY=new Array(0,0,0,0);var hint,hintfade,lastfav;var mposX=0,mposY=0;function initsearchmenu(n){object=document.getElementById(n);object.onmousemove=function(){showhint(0,true,0,0,this);}
object.onmouseout=function(){showhint(0,false);if(n==activesearchmenu)
document.getElementById(n).className="searchmenuSet";else
document.getElementById(n).className="searchmenuOff";}
object.onclick=function(){setsearchmenuhtml(n);}}
function setsearchmenuhtml(n){if(activesearchmenu!="")document.getElementById(activesearchmenu).className="searchmenuOff";if(activesearchmenu!=n){if(n=="search01")document.getElementById("searchOption").innerHTML=searchResetHTML;else
if(n=="search02")document.getElementById("searchOption").innerHTML=searchGoogleHTML;else
if(n=="search03")document.getElementById("searchOption").innerHTML=searchIMDbHTML;else
if(n=="search04")document.getElementById("searchOption").innerHTML=searchWikipediaHTML;if(n!="search01")document.getElementById('searchtext').setAttribute("autocomplete","on");else document.getElementById('searchtext').setAttribute("autocomplete","off");}
activesearchmenu=n;document.getElementById(activesearchmenu).className="searchmenuSet";document.getElementById('searchtext').focus();}
function initsinglies(){object=document.getElementById('reset-web');resetWeb=object;object.onkeydown=function(e){if(!e)e=window.event;if((e.keyCode==32)&&(e.shiftKey)){if(activesearchmenu=="search01")setsearchmenuhtml("search02");else
if(activesearchmenu=="search02")setsearchmenuhtml("search03");else
if(activesearchmenu=="search03")setsearchmenuhtml("search04");else
if(activesearchmenu=="search04")setsearchmenuhtml("search01");e.cancelBubble=true;if(e.stopPropagation)e.stopPropagation();return false;}}
object.onkeyup=function(e){if(!e)e=window.event;if((e.keyCode==32)&&(e.shiftKey)){e.cancelBubble=true;if(e.stopPropagation)e.stopPropagation();return false;}}
object.onkeypress=object.onkeyup;}
function initcommons(){hint=document.getElementById('hint');document.onmousemove=getMouseXY;ostyle=document.getElementById("ajaxprogress").style;if(is_ie)
ostyle.setExpression("top","eval(document.documentElement.scrollTop)+5");else
ostyle.position="fixed";if(document.getElementById('searchtext')!=null)initcb("searchtext");if(document.getElementById('searchfav')!=null){initcb_fav("searchfav");initFavCombo();}}
function searchsubmit(){if(activesearchmenu=="search01"){value=trim(document.getElementById("searchtext").value);v_op1=document.getElementById('op1').checked;if(document.getElementById('op3').checked)
return jumpWeb(value);else return document.location=(value.length>0)?((v_op1?"~":"")+value):"";}
else
if(activesearchmenu=="search02"){v_op1=document.getElementById('op1').checked;v_op2=document.getElementById('op2').checked;return document.location="http://"+(v_op2?"groups":"www")+".google.hu/"+(v_op2?"groups":"search")+"?hl=hu"+(v_op2?"&btnG=0":"")+"&q="+escape(document.getElementById('searchtext').value)+(v_op1?"&lr=lang_hu":"");}
else
if(activesearchmenu=="search03"){v_op1=document.getElementById('op1').checked;return document.location="http://www.google.hu/search?hl=hu&btn"+(v_op1?"I":"G")+"=0"+"&q="+escape(document.getElementById('searchtext').value+" site:imdb.com");}
else
if(activesearchmenu=="search04"){v_op1=document.getElementById('op1').checked;v_op2=document.getElementById('op2').checked;return document.location="http://www.google.hu/search?hl=hu&btn"+(v_op2?"I":"G")+"=0"+"&q="+escape(document.getElementById('searchtext').value+" site:"+(v_op1?"hu.":"")+"wikipedia.org");}}
function getMouseXY(e){if(activeDrag>0){if(is_ie){dragObj.setExpression("top","eval(document.documentElement.scrollTop)+"+(mposY-dragY-document.documentElement.scrollTop));document.execCommand("Unselect");}else{resetWeb.focus();dragObj.top=(mposY-dragY)+"px";}
dragObj.left=(mposX-dragX)+"px";}else{tempObj=is_ie?event.srcElement:e.target;if(tempObj!=hoverObj){if(tempObj.className=="b")v(tempObj,'bH');if((typeof hoverObj!="undefined")&&(hoverObj.className=="bH"))v(hoverObj,'b');hoverObj=tempObj;}}
mposX=is_ie?window.event.clientX+document.documentElement.scrollLeft+document.body.scrollLeft:e.pageX;mposY=is_ie?window.event.clientY+document.documentElement.scrollTop+document.body.scrollTop:e.pageY;if(activehintid>-1){x=activeHintXY[0]+((activeHintXY[2]>activeHintXY[3])?parseInt(activeHintXY[2]/2):activeHintXY[2]);y=activeHintXY[1]+((activeHintXY[2]<activeHintXY[3])?parseInt(activeHintXY[3]/2):activeHintXY[3]);hint.style.top=y+"px";hint.style.left=x+"px";if(hint.style.top!=mposY)
hint.style.top=(hint.offsetHeight+mposY+16-arrayPageScroll[1]>arrayPageSize[3])?(mposY-hint.offsetHeight)+"px":(mposY+16)+"px";if(hint.style.left!=mposX)
hint.style.left=(hint.offsetWidth+mposX+8>arrayPageSize[2])?(mposX-hint.offsetWidth)+"px":(mposX+8)+"px";}
return true;}
function drag(s){if(typeof s=="undefined"){activeDrag=0;return true;}
dragObj=document.getElementById(s).style;dragX=mposX-parseInt(dragObj.left+0);dragY=mposY-parseInt(dragObj.top+0);if(is_ie){window.event.cancelBubble=true;window.event.returnValue=false;}
document.onmouseup=new Function("drag()");activeDrag=1;}
function rsoff(){showhint(100,false);}
function rshowhint(i,b,t,a,o){if(!b||(i==101)){hint.style.visibility="hidden";hint.style.display="none";activehintid=-1;return 0;}
if(activehintid!=i){if(activehintid==-1){getPageSize();getPageScroll();}
hint.style.visibility="visible";hint.style.display="block";if(t)hint.innerHTML=t+(a?tipp[a]:"")+"&nbsp;&nbsp;";else hint.innerHTML=tipp[i]+"&nbsp;&nbsp;";activehintid=i;}}
function findPos(obj){curleft=0,curtop=0,curwidth=0,curheight=0;if(obj.offsetParent){curleft=obj.offsetLeft;curtop=obj.offsetTop;curwidth=obj.offsetWidth;curheight=obj.offsetHeight;while(obj=obj.offsetParent){curleft+=obj.offsetLeft;curtop+=obj.offsetTop;}}
return[curleft,curtop,curwidth,curheight];}
function visbl(i,b){ostyle=document.getElementById(i).style;if(!b){ostyle.visibility="hidden";ostyle.display="none";}else{ostyle.visibility="visible";ostyle.display="block";}}
function iep(i){visbl(i,(document.getElementById(i).innerHTML!=""));}
function setOverlay(o,t){ostyle=document.getElementById("overlay").style;if(typeof t!="undefined")ostyle.backgroundColor=(t?"#000000":"#FFFFFF");if(is_ie){ostyle.position="absolute";ostyle.setExpression("top","eval(document.documentElement.scrollTop)");ostyle.setExpression("height","eval(document.documentElement.clientHeight)");ostyle.filter="alpha(opacity=70)";}else{ostyle.position="fixed";ostyle.top="0px";ostyle.height="100%";ostyle.opacity="0.7";}
ostyle.visibility=(o?"visible":"hidden");ostyle.display=(o?"block":"none");}
function rollDown(o,t,b,m){if(document.getElementById(o)!=null){ostyle=document.getElementById(o).style;if(typeof m=="undefined")m=-1;if(m==-1){ostyle.visibility="visible";ostyle.display="block";ostyle.overflow="hidden";ostyle.height=b+"px";}
m++;ostyle.height=(b+slide[m])+"px";if((b+slide[m])<t)
setTimeout("rollDown('"+o+"',"+t+","+b+","+m+")",15);else{ostyle.overflow="visible";ostyle.height="";}}}
function rollUp(o,t,b,m){if(document.getElementById(o)!=null){ostyle=document.getElementById(o).style;if(typeof m=="undefined"){m=19;while(slide[m]>(t-b)){m--;}
m++;ostyle.overflow="hidden";}
m--;ostyle.height=(b+slide[m])+"px";if(m>0)
setTimeout("rollUp('"+o+"',"+t+","+b+","+m+",1)",15);else{if(b==0)ostyle.visibility="hidden";ostyle.height=b+"px";document.getElementById(o).parentNode.removeChild(document.getElementById(o));}}}
function setOpacity(n,v){ostyle=document.getElementById(n).style;if(is_ie)
ostyle.filter="alpha(opacity="+(v)+")";else
ostyle.opacity=(v/100);}
function addtag(o){values=(document.getElementById("LINK_TAGS").value+","+o+",").split(",");currentValue="";for(var j=0;j<values.length-1;j++)
if(trim(values[j])!="")currentValue=listAppend(currentValue,trim(values[j]),",");document.getElementById("LINK_TAGS").value=currentValue+", ";}
function initcb(id){cbGlobal=new ComboBox(id,realCallback,false);}
function initcb_fav(id){cbGlobal=new ComboBox(id,realCallbackFav,false);}
function initcb_tag(id,tl){cbTag=new ComboBox(id,tagCallback,true);taglist=tl;}
function tagCallback(value){names=(value.length>0)?taglist:"";var items=new Array();var ovalue="";ovalue=value;if(value.length>0){names=names.split(",");value=value.toLowerCase();j=0;for(var i=0;i<names.length;i++)
if((names[i].toLowerCase().indexOf(value)==0)&&(j<20)){items.push(names[i]);j++;}}
cbTag.setItems(items);}
function nameCallback(value,names){if(trim(document.getElementById(cbGlobal.id).value)!=trim(value)){setAjax(false,false,false);realCallback(document.getElementById(cbGlobal.id).value);return 0;}
var items=new Array();var ovalue="";ovalue=value;if(document.getElementById(cbGlobal.id).value!=value){value=document.getElementById(cbGlobal.id).value;names="";}
if(value.length>0){names=names.split("∞");value=value.toLowerCase();for(var i=0;i<Math.min(names.length,20);i++)
if(names[i].toLowerCase().indexOf(value)>=0)items.push(names[i]);}
cbGlobal.setItems(items);setAjax(false,false,false);}
function nameCallbackFav(value,names){if(trim(document.getElementById(cbGlobal.id).value)!=trim(value)){setAjax(false,false,false);realCallbackFav(document.getElementById(cbGlobal.id).value);return 0;}
var items=new Array();var ovalue="";ovalue=value;if(document.getElementById(cbGlobal.id).value!=value){value=document.getElementById(cbGlobal.id).value;names="";}
if(value.length>0){names=names.split("∞");value=value.toLowerCase();for(var i=0;i<Math.min(names.length,10);i++)
if(names[i].toLowerCase().indexOf(value)>=0)items.push(names[i]);}
cbGlobal.setItems(items);setAjax(false,false,false);}
function ov(o){o.style.backgroundImage="url(img/bsc/user_bg_inv.png)";}
function ou(o){o.style.backgroundImage="url(img/bsc/user_bg.png)";}
function v(o,c){o.className=c;}
function minmax(e,b){o=document.getElementById(e);if(o.className=="min"){v(o,"");document.getElementById(b).src="img/bsc/min.gif";}else{v(o,"min");document.getElementById(b).src="img/bsc/max.gif";}}
function bodyon(){ostyle=document.getElementById("reset-web").style;ostyle.visibility="visible";ostyle.display="block";}
function setpresookie(){var date=new Date();date.setTime(date.getTime()+(30*60*1000));var expires="; expires="+date.toGMTString();document.cookie="presookie=off"+expires+"; path=/";}
function getPageScroll(){var yScroll;if(self.pageYOffset){yScroll=self.pageYOffset;}else if(document.documentElement&&document.documentElement.scrollTop){yScroll=document.documentElement.scrollTop;}else if(document.body){yScroll=document.body.scrollTop;}
arrayPageScroll=new Array('',yScroll)
return arrayPageScroll;}
function getPageSize(){var xScroll,yScroll;if(window.innerHeight&&window.scrollMaxY){xScroll=document.body.scrollWidth;yScroll=window.innerHeight+window.scrollMaxY;}else if(document.body.scrollHeight>document.body.offsetHeight){xScroll=document.body.scrollWidth;yScroll=document.body.scrollHeight;}else{xScroll=document.body.offsetWidth;yScroll=document.body.offsetHeight;}
var windowWidth,windowHeight;if(self.innerHeight){windowWidth=self.innerWidth;windowHeight=self.innerHeight;}else if(document.documentElement&&document.documentElement.clientHeight){windowWidth=document.documentElement.clientWidth;windowHeight=document.documentElement.clientHeight;}else if(document.body){windowWidth=document.body.clientWidth;windowHeight=document.body.clientHeight;}
if(yScroll<windowHeight){pageHeight=windowHeight;}else{pageHeight=yScroll;}
if(xScroll<windowWidth){pageWidth=windowWidth;}else{pageWidth=xScroll;}
arrayPageSize=new Array(pageWidth,pageHeight,windowWidth,windowHeight)
return arrayPageSize;}
function getOffsets(object,offsets){if(!offsets){offsets=new Object();offsets.x=offsets.y=0;}
if(typeof object=="string")
object=document.getElementById(object);offsets.x+=object.offsetLeft;offsets.y+=object.offsetTop;do{object=object.offsetParent;if(!object)
break;offsets.x+=object.offsetLeft;offsets.y+=object.offsetTop;}while(object.tagName.toUpperCase()!="BODY");return offsets;}
function listAppend(list,value,delimiter){if(typeof delimiter=="undefined")
delimiter=",";if(list=="")
return value;else
return list+delimiter+value;}
function removeChildren(parent){for(var i=parent.childNodes.length-1;i>=0;i--){parent.removeChild(parent.childNodes[i]);}}
function gval(id){s=document.getElementById(id).value;return id+"="+s.length+":"+s+";";}
function setStars(mode,id,avr,i,sp){if(ajaxReq)return false;if(mode==0){document.getElementById("str0_"+id).className='vs'+(i>-1?'3':'4');document.getElementById("str1_"+id).className='vs'+(i>0?'3':'4');document.getElementById("str2_"+id).className='vs'+(i>1?'3':'4');document.getElementById("str3_"+id).className='vs'+(i>2?'3':'4');document.getElementById("str4_"+id).className='vs'+(i>3?'3':'4');}else if(mode==1){document.getElementById("str0_"+id).className='vs'+(avr>0?(avr-0.5>0?(0+sp):(2+sp)):(1+sp));document.getElementById("str1_"+id).className='vs'+(avr>1?(avr-0.5>1?(0+sp):(2+sp)):(1+sp));document.getElementById("str2_"+id).className='vs'+(avr>2?(avr-0.5>2?(0+sp):(2+sp)):(1+sp));document.getElementById("str3_"+id).className='vs'+(avr>3?(avr-0.5>3?(0+sp):(2+sp)):(1+sp));document.getElementById("str4_"+id).className='vs'+(avr>4?(avr-0.5>4?(0+sp):(2+sp)):(1+sp));}else if(mode==2)voting(id,i);}
function LTrim(value){var re=/\s*((\S+\s*)*)/;return value.replace(re,"$1");}
function RTrim(value){var re=/((\s*\S+)*)\s*/;return value.replace(re,"$1");}
function trim(value){return LTrim(RTrim(value));}
function Left(str,n){if(n<=0)return"";else if(n>String(str).length)return str;else return String(str).substring(0,n);}
function Right(str,n){if(n<=0)return"";else if(n>String(str).length)return str;else{var iLen=String(str).length;return String(str).substring(iLen,iLen-n);}}
function toTop(){t=document.documentElement.scrollTop-50;if(t>2){document.documentElement.scrollTop=t;setTimeout("toTop()",1);}else document.documentElement.scrollTop=0;}
function toHide(e,v,p){v=v/2;if(v>2){setOpacity(e,v);setTimeout("toHide('"+e+"',"+v+",'"+p+"')",100);}else document.getElementById(p).removeChild(document.getElementById(e));}
function searchparams(){return document.getElementById("searchparam").value+"#"+document.getElementById("tagparam").value;}
function getPageCoords(el){var coords={x:0,y:0};while(el){coords.x+=el.offsetLeft;coords.y+=el.offsetTop;el=el.offsetParent;}
return coords;}
function rmyfav(o,m){if(m<2){document.getElementById(o.id).style.backgroundColor=(m?"#ee0505":"#f0f0f0");var ffav=document.getElementById("firstfav").style;var dfav=document.getElementById("delfav").style;if(m){s=getPageCoords(document.getElementById(o.id));ffav.left=(s.x+8)+"px";ffav.top=(s.y+8)+"px";ffav.display="block";ffav.visibility="visible";dfav.left=(s.x+28)+"px";dfav.top=(s.y+8)+"px";dfav.display="block";dfav.visibility="visible";lastfav=o;}else{ffav.display="none";ffav.visibility="hidden";dfav.display="none";dfav.visibility="hidden";}}else
if(m==2){myfav(lastfav,1);}}
function previewShow(id){o=document.getElementById("dl"+id);if(document.getElementById("rsi"+id)!=null)
rollUp("rsi"+id,400,0);else{ra=document.getElementById("ra"+id).href;nd=document.createElement('div');nd.id="rsi"+id;nd.className="previewcont";fi=document.createElement("iframe");fi.className="preview";fi.frameBorder=0;me=document.createElement("div");me.className="previewmenu";me.innerHTML="<img onmousemove='showhint(7,1);' onmouseout='soff();' src=img/bsc/pclose.gif align=right class=cur onclick='rollUp(\""+nd.id+"\",400,0);soff();'>"+"<a href=\'"+ra+"\' target=_blank><img onmousemove='showhint(8,1);' onmouseout='soff();' src=img/bsc/pfull.gif align=right class=cur border=0></a>W E B O L D A L&nbsp;&nbsp;&nbsp;&nbsp;E L Ő N É Z E T";nd.appendChild(me);nd.appendChild(fi);o.parentNode.insertBefore(nd,o);rollDown(nd.id,400,0);fi.src=unescape(ra.substring(26));}}
function rssShow(id,rsshash){o=document.getElementById("dl"+id);if(document.getElementById("rsi"+id)!=null)
rollUp("rsi"+id,400,0);else{ra=document.getElementById("ra"+id).href;nd=document.createElement('div');nd.id="rsi"+id;nd.className="rsspreviewcont";fi=document.createElement("iframe");fi.className="preview";fi.frameBorder=0;me=document.createElement("div");me.className="rsspreviewmenu";me.innerHTML="<img id=ifloader"+id+" src=img/bsc/ifloader.gif align=left><img onmousemove='showhint(7,1);' onmouseout='soff();' src=img/bsc/rclose.gif align=right class=cur onclick='rollUp(\""+nd.id+"\",400,0);soff();'>"+"<a href=\'rss/"+rsshash+"\' target=_blank><img onmousemove='showhint(8,1);' onmouseout='soff();' src=img/bsc/rfull.gif align=right class=cur border=0></a>R S S&nbsp;&nbsp;&nbsp;&nbsp;O L V A S Ó";nd.appendChild(me);nd.appendChild(fi);o.parentNode.insertBefore(nd,o);rollDown(nd.id,400,0);fi.contentWindow.document.write("<h4>RSS betöltése...</h4>");fi.src="rss/"+rsshash+"&ifloader="+id;}}
function rssloaded(id){if(top.document.getElementById("ifloader"+id)!=null)
top.document.getElementById("ifloader"+id).style.visibility="hidden";resetWeb=document.getElementById('reset-web');initcommons();}
function initFavCombo(){s=getPageCoords(document.getElementById("searchfav"));document.getElementById("i2combo").style.left=s.x+"px";document.getElementById("i2combo").style.top=s.y+"px";}
function setFocus(i){document.getElementById(i).focus();}
function readybookmark(){var s='<a href="http://www.reset.hu/?DESC='+encodeURIComponent(document.getElementById('w_desc').value)+'&URL='+encodeURIComponent(document.getElementById('w_url').value)+'&TITLE='+encodeURIComponent(document.getElementById('w_title').value)+'" title="Bookmarkold az oldalt a reset.hu-ra!">'+'<img src="http://www.reset.hu/img/bsc/resethu_0';if(document.getElementById('w_1').checked)s=s+"1";else
if(document.getElementById('w_2').checked)s=s+"2";else
if(document.getElementById('w_3').checked)s=s+"3";else
if(document.getElementById('w_4').checked)s=s+"4";else
if(document.getElementById('w_5').checked)s=s+"5";else
if(document.getElementById('w_6').checked)s=s+"6";s=s+'.gif" border=0/></a>';if(!phpfx(0,s))return false;document.getElementById('reset_boomark_kod').innerHTML="Várj...";document.getElementById('reset_boomark_elonezet').innerHTML='<div class=center>'+s+'</div>';}
var jsreset=1;var ajaxReq=false;var ajaxProg=false;var ajaxBlack=false;var paramInnerhtlm=new Array("","","");function setAjax(req,prog,blk){if(typeof req=="undefined")req=ajaxReq;if(typeof prog=="undefined")prog=ajaxProg;if(typeof blk=="undefined")blk=ajaxBlack;ajaxReq=req;ajaxProg=prog;ajaxBlack=blk;ostyle=document.getElementById("ajaxprogress").style;if(req){document.getElementById("ajaxprogress").src="img/bsc/ajax_work.gif";ostyle.visibility="visible";ostyle.display="block";}else{ostyle.visibility="hidden";ostyle.display="none";}
setOverlay(prog,blk);return req;}
function setTimingFresh(e,a,i){paramInnerhtlm[i]=a;setTimeout("setFresh('"+e+"',"+i+")",1);document.getElementById("ajaxprogress").src="img/bsc/ajax_fresh.gif";}
function setFresh(e,i){document.getElementById(e).innerHTML=paramInnerhtlm[i];paramInnerhtlm[i]="";if((paramInnerhtlm[0]+paramInnerhtlm[1]+paramInnerhtlm[2])==""){setTimeout("setAjax(false,false,false)",200);toTop();}}
function install(aEvent){var params={"reset.hu Extension":{URL:aEvent.target.href,IconURL:aEvent.target.getAttribute("iconURL"),Hash:aEvent.target.getAttribute("hash"),toString:function(){return this.URL;}}};InstallTrigger.install(params);return false;}
function klikk(o){if(ajaxReq)return false;if(o.id=="signup")signup(-1);else if(o.id=="signupnext")signup(1);else if(o.id=="signupback")signup(0);else if(o.id=="signupcheck")signup(2);else if(o.id=="signupfinish")signup(3);else if(o.id=="forgottpsw")signup(4);else if(o.id=="forgottpswnext")signup(5);else if(o.id=="signin")signup(6,false);else if(o.id=="signinalt")signup(106,false);else if(o.id=="sendactivate")signup(7);else if(o.id=="logout")signup(8,false);else if(o.id=="regmodify")signup(9);else if(o.id=="pswchange")signup(10);else if(o.id=="pswchangedone")signup(11);else if(o.id=="picupload")signup(12);else if(o.id=="loginwin_btn")minmax("loginbox",o.id);else if(o.id=="startPixUpload")uploadPix(true);else if(o.id=="picuploadnext")signup(13);else if(o.id=="pixdel")uploadPix(false,"","");else if(o.id=="btn_newlink")linksave(-1,"");else if(o.id=="savelink")linksave(0);else if(o.id=="tagscrollbutton")tagwinopens();else if(o.id=="historyback")history.back();else if(o.id=="cancel")offPopup();else if(o.id=="cancel2")offPopup();else if(o.id=="btn_dellink")dellink(-3,0);else if(o.id=="viewmin")changeview(1);else if(o.id=="viewmax")changeview(0);else if(o.id=="orderall")changeorder(0);else if(o.id=="ordernew")changeorder(1);else if(o.id=="ordertop")changeorder(2);else if(o.id=="orderuall")changeorder(3);else if(o.id=="orderufav")changeorder(9);else if(o.id=="orderupriv")changeorder(10);else if(o.id=="orderuabc")changeorder(4);else if(o.id=="orderuhist")changeorder(5);else if(o.id=="ordertlot")changeorder(6);else if(o.id=="ordertnew")changeorder(7);else if(o.id=="orderttop")changeorder(8);else if(o.id=="lockbutton")lock();else if(o.id=="favoritebutton")favorite(0);else if(o.id=="firstfav")favorite(1,lastfav.id.substring(3));else if(o.id=="delfav")favorite(2,lastfav.id.substring(3));else if((Left(o.id,8)=="savelink")&&(o.id.length>8))linksave(-1,o.id.substring(8));else if((Left(o.id,8)=="savecomm")&&(o.id.length>8))linksave(-4,o.id.substring(8));else if((Left(o.id,8)=="showlink")&&(o.id.length>8))linksave(-100,o.id.substring(8));else if((Left(o.id,8)=="commlink")&&(o.id.length>8))linksave(-102,o.id.substring(8));else if((Left(o.id,9)=="errorlink")&&(o.id.length>9))linksave(-101,o.id.substring(9));else if(Left(o.id,7)=="dellink")dellink(-2,o.id.substring(7));else if(o.id=="tagsviewchange")tagtask(0);else if(o.id=="reltagsviewchange")tagtask(1);else if((Left(o.id,12)=="tagfilterdel")&&(o.id.length>12))tagtask(2,o.id.substring(12));else if((Left(o.id,12)=="tagfilteradd")&&(o.id.length>12))tagtask(3,o.id.substring(12));else if((Left(o.id,12)=="tagfilterset")&&(o.id.length>12))tagtask(4,o.id.substring(12));else if(o.id=="readme")readme(0);else if(o.id=="goreg")readme(1);else if(o.id=="downloadTools")readme(2);else if(o.id=="hidedoreg")presoff();else if((Left(o.id,8)=="locklink")&&(o.id.length>8))linkdetail(0,o.id.substring(8));else if((Left(o.id,7)=="favlink")&&(o.id.length>7))linkdetail(1,o.id.substring(7));}
function popupShow(v,l,t){ostyle=document.getElementById("popfly").style;if(!v){ostyle.visibility="hidden";ostyle.display="none";document.getElementById("popfly").innerHTML="";return false;}
if(is_ie){ostyle.setExpression("top","eval(document.documentElement.scrollTop)+"+t);}else{ostyle.position="fixed";ostyle.top=t+"px";}
ostyle.visibility="visible";ostyle.display="block";ostyle.left=l+"px";return true;}
function signup(p,f){setAjax(true,(typeof f!="undefined")?f:true,true);w=getPageSize();d="";if(p==1)d="REG_ACCEPT="+(document.getElementById("REG_ACCEPT").checked?"4:true;":"5:false;");else if((p==0)||(p==2)||(p==3))d=gval("REG_EMAIL")+gval("REG_USER")+gval("REG_PSW")+gval("REG_PSW2")+gval("REG_TURING");else if(p==5)d=gval("REG_EMAIL")+gval("REG_TURING");else if(p==6)d=gval("LOGIN_EMAIL")+gval("LOGIN_PSW");else if(p==106){d=gval("LOGIN_EMAIL")+gval("LOGIN_PSW")+gval("LINK_TITLE")+gval("LINK_URL")+gval("LINK_DESC")+gval("LINK_MODE");if(document.getElementById("LINK_MAGIC").value=="1FAV")p=105;}
else if(p==7)d=gval("LOGIN_TURING");else if(p==11)d=gval("REG_PSW")+gval("REG_PSW2")+gval("REG_TURING");else if(p==13)d=gval("userpix")+gval("REG_TURING");rajax_regPopup(w[2],w[3],p,d);}
function linksave(p,id){setAjax(true,true,(p!=-100)&&(p!=-102));w=getPageSize();d="";if((p==-1)||(p==-100)||(p==-101)||(p==-102)||(p==-4)){d=id;document.getElementById("jumpparam").value=id;}
if(p==0){d=gval("LINK_TITLE")+gval("LINK_URL")+gval("LINK_TAGS")+gval("LINK_DESC")+gval("LINK_MEMO")+gval("LINK_MAGIC")+gval("LINK_PRIVATE")+gval("LINK_FAVORITE")+((document.getElementById("searchparam")==null)?"":gval("searchparam"))+((document.getElementById("jumpparam")==null)?"":gval("jumpparam"));}
rajax_linkPopup(w[2],w[3],p,d);}
function uploadPix(f,m,p){if(f){if(document.getElementById("pix").value==""){document.getElementById("pixerror").innerHTML="Nincs fájl kiválasztva!";visbl("pixerror",(document.getElementById("pixerror").innerHTML!=""));return false;}
setAjax(true,true,true);document.getElementById("pixerror").innerHTML="";document.picupload.submit();}else{setAjax(false,true,true);document.picupload.reset();document.getElementById("pixerror").innerHTML=m;document.getElementById("mypix").src=(p!="")?"usr/_mini/"+p+".jpg":"img/bsc/user.png";document.getElementById("userpix").value=(p!="")?"new":"del";}
iep("pixerror");}
function tagwinopens(){ostyle=document.getElementById("tagscrolledwin").style;ostyle.height=(ostyle.height=="auto")?"60px":"auto";document.getElementById("tagscrollbutton").src="img/bsc/arrow_"+((ostyle.height=="auto")?"down":"right")+".gif";}
function page(o){if(ajaxReq)return false;setAjax(true,false,false);rajax_pager(searchparams(),o);}
function dellink(m,i){if(ajaxReq)return false;setAjax(true,true,true);w=getPageSize();d=(i==0)?gval("LINK_MAGIC"):i;rajax_linkPopup(w[2],w[3],m,d);}
function linkdetail(m,i){if(ajaxReq)return false;setAjax(true,false,false);w=getPageSize();rajax_linkDetail(w[2],w[3],m,i,(document.getElementById("searchparam")==null)?"":gval("searchparam"));}
function changeview(t){if(ajaxReq)return false;values=document.getElementById("searchparam").value.split(",");if(values[1]==t)return false;setAjax(true,false,false);rajax_pager(searchparams(),0,t);v(document.getElementById("viewmin"),"viewmin"+(t==1?"Set":""));v(document.getElementById("viewmax"),"viewmax"+(t==0?"Set":""));}
function changeorder(t){if(ajaxReq)return false;values=document.getElementById("searchparam").value.split(",");if(values[2]==t)return false;setAjax(true,false,false);rajax_pager(searchparams(),0,values[1],t);if((t>-1)&&(t<3)){v(document.getElementById("orderall"),(t==0)?"vieworderSet":"vieworder");v(document.getElementById("ordernew"),(t==1)?"vieworderSet":"vieworder");v(document.getElementById("ordertop"),(t==2)?"vieworderSet":"vieworder");}else
if(((t>2)&&(t<6))||t==9||t==10){v(document.getElementById("orderuall"),(t==3)?"vieworderSet":"vieworder");v(document.getElementById("orderuabc"),(t==4)?"vieworderSet":"vieworder");v(document.getElementById("orderuhist"),(t==5)?"vieworderSet":"vieworder");if(document.getElementById("orderufav"))v(document.getElementById("orderufav"),(t==9)?"vieworderSet":"vieworder");if(document.getElementById("orderupriv"))v(document.getElementById("orderupriv"),(t==10)?"vieworderSet":"vieworder");}else
if((t>5)&&(t<9)){v(document.getElementById("ordertlot"),(t==6)?"vieworderSet":"vieworder");v(document.getElementById("ordertnew"),(t==7)?"vieworderSet":"vieworder");v(document.getElementById("orderttop"),(t==8)?"vieworderSet":"vieworder");}}
function voting(i,v){if(ajaxReq)return false;setAjax(true,false,false);w=getPageSize();rajax_linkVoting(i,v,w[2],w[3]);}
function lock(){o=document.getElementById("LINK_PRIVATE");o.value=(o.value=="")?"1":"";v(document.getElementById("lockbutton"),(o.value=="")?"private":"privateOn");}
function favorite(m,va){if(m==0){o=document.getElementById("LINK_FAVORITE");o.value=((o.value=="0")||(o.value=="-"))?"+":"-";v(document.getElementById("favoritebutton"),((o.value=="0")||(o.value=="-"))?"favorite":"favoriteOn");}else{lastfav.style.backgroundColor="#f0f0f0";if(ajaxReq)return false;setAjax(true,false,false);w=getPageSize();rajax_favorite(va,m,w[2],w[3]);}}
function offPopup(){popupShow(false);setAjax(false,false,false);}
function realCallback(value){if(activesearchmenu!="search01")return 0;value=trim(value);if(value.length>0){if(ajaxReq)return false;setAjax(true,false,false);rajax_searchCombo(value,document.getElementById("op1").checked?0:(document.getElementById("op2").checked?1:2));}else nameCallback(value,"");}
function realCallbackFav(value){soff();value=trim(value);if(value.length>0){if(ajaxReq)return false;setAjax(true,false,false);rajax_searchComboFav(value);}else nameCallbackFav(value,"");}
function tagtask(i,t){if(ajaxReq)return false;setAjax(true,false,false);if(i<2)
rajax_changeTagsview(searchparams(),i,i==0?0:document.getElementById("reltagsview").value);else
rajax_userTagFilter(searchparams(),i,t,document.getElementById("reltagsview").value);}
function readme(t){if(ajaxReq)return false;setAjax(true,true,false);w=getPageSize();rajax_readme(t,w[2],w[3]);}
function jumpWeb(n){if(ajaxReq)return false;setAjax(true,true,true);w=getPageSize();t=n?n:document.getElementById("searchfav").value;rajax_jumpWeb(t,w[2],w[3],n?1:0);}
function presoff(){var o=document.getElementById("donowreg");if(o!=null){setpresookie();toHide("donowreg",100,"links");}}
function phpfx(i,s){if(ajaxReq)return false;setAjax(true,false,false);rajax_phpFunc(i,s);return true;}
var jsrajax=1;function ComboBox(id,callback,multi){var self=this;this.config=new Object();this.config["allowMultipleValues"]=multi;this.callback=callback;this.availableItems=new Array();this.selectedItemIndex=-1;this.id=id;this.field=document.getElementById(id);this.dropdown=((id=="searchtext")||(id=="searchfav"))?document.getElementById("i2combo"):document.getElementById("icombo");this.isDropdownShowing=false;this.dropdown.className="comboBoxList";var offsets=getOffsets(this.field);this.dropdown.style.width=(this.field.offsetWidth?this.field.offsetWidth:100)-2+"px";this.hideDropdown();this.field.comboBox=this;this.field.oldValue=this.field.value;this.field.onkeyup=ComboBox.onKeyUp;this.field.moveCaretToEnd=function(){if(this.createTextRange){var range=this.createTextRange();range.collapse(false);range.select();}else if(this.setSelectionRange){this.focus();var length=this.value.length;this.setSelectionRange(length,length);}}
this.field.onfocus=function(){return!self.isDropdownShowing;}
this.field.onblur=function(){var cb=this.comboBox;this.hideTimeout=setTimeout(function(){cb.hideDropdown();},100);}
this.getConfigParam=function(name,defVal){return self.config[name]||defVal;}}
ComboBox.onKeyDown=function(e){if(!e)e=window.event;var capture=function(){e.cancelBubble=true;if(e.stopPropagation)e.stopPropagation();}
switch(e.keyCode){case 13:case 9:this.comboBox.chooseSelection();capture();return false;case 27:this.comboBox.hideDropdown();capture();case 38:this.comboBox.selectPrevious();capture();break;case 40:this.comboBox.selectNext();capture();break;}}
ComboBox.onKeyUp=function(e){if(!e)e=window.event;var capture=function(){e.cancelBubble=true;if(e.stopPropagation)e.stopPropagation();}
switch(e.keyCode){case 38:case 40:this.moveCaretToEnd();capture();break;default:if(this.value!=this.oldValue){this.comboBox.valueChanged();this.oldValue=this.value;}
capture();}}
ComboBox.prototype.valueChanged=function(){var value=this.field.value;if(this.getConfigParam("allowMultipleValues",false)){value=value.split(this.getConfigParam("valueDelimiter",","));value=value[value.length-1].replace(/^ +/,"").replace(/ +$/,"");}
var a=this.callback(value,this);}
ComboBox.prototype.setItems=function(items){this.availableItems=items;this.populateDropdown();}
ComboBox.prototype.populateDropdown=function(){if(this.availableItems.length>0){removeChildren(this.dropdown);for(var i=0;i<this.availableItems.length;i++){var item=document.createElement("div");item.className="comboBoxItem";item.innerHTML=this.availableItems[i];item.id="item_"+this.availableItems[i];item.comboBox=this;item.comboBoxIndex=i;item.onmouseover=function(){this.comboBox.select(this.comboBoxIndex);};item.onclick=function(){this.comboBox.choose(this.comboBoxIndex);};this.dropdown.appendChild(item);}
this.selectedItemIndex=0;this.updateSelection();this.showDropdown();}else{this.selectedItemIndex=-1;this.hideDropdown();}}
ComboBox.prototype.choose=function(index){if(this.select(index))
this.chooseSelection();}
ComboBox.prototype.chooseSelection=function(){var i=this.selectedItemIndex;var a=this.availableItems;if(i>=0&&i<a.length){var valueToAdd=a[i].replace(/<[^>]+>/g,"");if(this.getConfigParam("allowMultipleValues",false)){var currentValue="";var delim=this.getConfigParam("valueDelimiter",",");values=this.field.value.split(delim);for(var j=0;j<values.length-1;j++){if(trim(values[j])!="")
currentValue=listAppend(currentValue,trim(values[j]),delim);}
this.field.value=listAppend(currentValue,valueToAdd,delim)+", ";}else{this.field.value=valueToAdd;}
this.field.oldValue=this.field.value;this.field.focus();this.field.moveCaretToEnd();this.hideDropdown();}}
ComboBox.prototype.select=function(index){if(index<0||index>=this.availableItems.length)
return false;this.selectedItemIndex=index;this.updateSelection();return true;}
ComboBox.prototype.selectNext=function(){if(this.selectedItemIndex>=this.availableItems.length-1)
return false;this.selectedItemIndex++;this.updateSelection();return true;}
ComboBox.prototype.selectPrevious=function(){if(this.selectedItemIndex<=0)
return false;this.selectedItemIndex--;this.updateSelection();}
ComboBox.prototype.showDropdown=function(){clearTimeout(this.field.hideTimeout);this.dropdown.style.display='block';this.field.onkeydown=ComboBox.onKeyDown;this.isDropdownShowing=true;}
ComboBox.prototype.hideDropdown=function(){var self=this;setTimeout(function(){self.isDropdownShowing=false;},100);this.field.onkeydown=null;this.dropdown.style.display='none';}
ComboBox.prototype.updateSelection=function(){for(var i=0;i<this.dropdown.childNodes.length;i++){if(i==this.selectedItemIndex){this.dropdown.childNodes[i].className+=" comboBoxSelectedItem";}else{this.dropdown.childNodes[i].className=this.dropdown.childNodes[i].className.replace(/ *comboBoxSelectedItem */g,"");}}}