var debug=0;var status='';function createRequestObject(){var ro;var browser=navigator.appName;if(browser=='Microsoft Internet Explorer'){ro=new ActiveXObject("Microsoft.XMLHTTP");}else{ro=new XMLHttpRequest();}
return ro;}
var http=createRequestObject();function sendReq(action,b){if(b){b='&amp;b='+b;}else{var b='';}
var url='';if(action=='close'){url='cron.php?action=cron';}else{var filename=document.location.href;var end=(filename.indexOf("?")==-1)?filename.length:filename.indexOf("?");url=filename.substring(filename.lastIndexOf("/")+1,end);url+='?a=ajax&amp;action='+action+b;url=url.replace(/amp;/ig,"");}
if(debug){status+='URL: '+url+'\\n';alert(status);}
try{http.open('get',url);if(debug)
status+='Request sent\\n\\n';http.onreadystatechange=handleResponse;http.send(null);}catch(exception){if(debug)alert('exception error is . . . \\n\\n'+exception);}}
function handleResponse(){if(http.readyState==4){var response=http.responseText;var update=new Array();var sep='|';if(response.indexOf('~~|~~')!=-1){sep='~~|~~';}
if(response.indexOf(sep)!=-1){update=response.split(sep);if(debug){alert('Debug: \\n\\t'+status+'\\n\\nupdate[0] = '+update[0]+'\\n\\nupdate[1] = '+update[1]);status='';}
if(document.getElementById(update[1]))
document.getElementById(update[1]).innerHTML=update[0];if(document.getElementById(update[2]))
document.getElementById(update[2]).innerHTML=update[0];if(document.getElementById(update[3]))
document.getElementById(update[3]).innerHTML=update[0];if(document.getElementById(update[4]))
document.getElementById(update[4]).innerHTML=update[0];}else if(debug)
alert('Debug: \\n\\t'+status+'\\n\\n'+response);}}