window.onload = function(){}function changepic(img_id,img_src) {	var elem = getElem(thelayer);	elem.src=img_src;}function showid(id) {	var elem = getElem(id);	elem.style.display='block';}function hideid(id) {	var elem = getElem(id);	elem.style.display='none';}function toggleLayer(thelayer){	var elem = getElem(thelayer);	vis = elem.style;	if(vis.display==''&&elem.offsetWidth!=undefined&&elem.offsetHeight!=undefined){		vis.display = (elem.offsetWidth!=0&&elem.offsetHeight!=0)?'block':'none';	}	vis.display = (vis.display==''||vis.display=='block')?'none':'block';}function getElem(id){	var elem;	if( document.getElementById ){		elem = document.getElementById(id);	}else if( document.all ){		elem = document.all[id];	}else if( document.layers ){		elem = document.layers[id];	}	return elem}function ajax(page,passvar,div,str_return,jsondecode) {	xmlHttp=GetXmlHttpObject()	if (xmlHttp==null) {		alert ("Browser does not support HTTP Request")		return	}	var url=page+".php"	url=url+"?sid="+Math.random()	url=url+"&"+passvar	if (str_return != ""){		xmlHttp.open("GET",url,false)		xmlHttp.onreadystatechange=function(){stateChanged(div)}			} else {		xmlHttp.open("GET",url,true)		xmlHttp.onreadystatechange=function(){stateChanged(div)}	}	xmlHttp.send(null)	if (str_return != ''){		if (div != ''){ betterInnerHtml(div, xmlHttp.responseText) }		if (jsondecode != ''){ return parseJSON(xmlHttp.responseText) }		else { return xmlHttp.responseText }	}}function stateChanged(div) {	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete") {		if (div != ''){			betterInnerHtml(div, xmlHttp.responseText)		}	}}function GetXmlHttpObject() {	var xmlHttp=null;	try {  xmlHttp=new XMLHttpRequest(); }	catch (e) {		try { xmlHttp=new ActiveXObject("Msxml2.XMLHTTP"); }		catch (e) { xmlHttp=new ActiveXObject("Microsoft.XMLHTTP"); }	}	return xmlHttp;}function betterInnerHtml(id, content){	var randomstring = randomstr(5);	var newdiv = document.createElement(randomstring);	var ctrl;	ctrl = getElem(id);	removeChildNodes(ctrl);	newdiv.innerHTML = content; 	var container = document.getElementById(id);	container.appendChild(newdiv);}function removeChildNodes(ctrl) {	while (ctrl.childNodes[0]) {		ctrl.removeChild(ctrl.childNodes[0]);	}}function randomstr(howlong) {	var text = "";	var possible = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";	for( var i=0; i <= howlong; i++ ) text += possible.charAt(Math.floor(Math.random() * possible.length));	return text;}function parseJSON(json){        if(/^("(\\.|[^"\\\n\r])*?"|[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t])+?$/.test(json)){            var j = eval('(' + json + ')');            return j;	}}