function clearText(theField)
{
theField.value = '';
}
function tdmouseover(el) {
	el.style.color = "#F4F4F4"
	el.style.backgroundColor = "#CCCCCC"
}
function tdmouseout(el) {
	el.style.color = "black"
	el.style.backgroundColor = "#F4F4F4"
}
function tdmouseover2(el) {
	el.style.color = "white"
	el.style.backgroundColor = "#006600"
}
function tdmouseout2(el) {
	el.style.color = "black"
	el.style.backgroundColor = "white"
}
function tdmouseover3(el) {
	el.style.color = "white"
	el.style.backgroundColor = "#EA0000"
}
function tdmouseout3(el) {
	el.style.color = "white"
	el.style.backgroundColor = "#ff8b00"
}
function loadsmap(country,state,city,address,adid){
	if(country != "" && city != ""){
		new Ajax.Updater("mapdiv", "/loadmap.php?mode=small&country="+country+"&state="+state+"&city="+city+"&address="+address+"&adid="+adid, {asynchronous:true,evalScripts:true}); 
	}else{
		alert("Please fill all the address fields. State is optional.");
	}
}

function loadit(coords,coords2,type){
	if(type == 'city'){
		new Ajax.Updater("xmlmapdiv", "/loadxmlmap.php?country="+coords+"&city="+coords2+"&type="+type, {asynchronous:true,evalScripts:true}); 
	}else{
		
	}
}

function loadsmap2(country,state,city,address,adid){
	if(country != "" && city != ""){
		new Ajax.Updater("mapdiv", "/loadmap2.php?mode=small&country="+country+"&state="+state+"&city="+city+"&address="+address+"&adid="+adid, {asynchronous:true,evalScripts:true}); 
	}else{
		alert("Please fill all the address fields. State is optional.");
	}
}

function loadit2(coords,coords2,type){
	if(type == 'city'){
		new Ajax.Updater("xmlmapdiv", "/loadxmlmap2.php?country="+coords+"&city="+coords2+"&type="+type, {asynchronous:true,evalScripts:true}); 
	}else{
		
	}
}

function loadbox(me){
	if (me.style.display==""){
		me.style.display="inline";
	}else{
		me.style.display="";
	}
}

function laptopinfo(infotype,id,level){
	
	new Ajax.Updater(infotype, "newlap.php?infotype="+infotype+"&id="+id+"&level="+level, {asynchronous:true,evalScripts:true}); 
	
}

function registernow(me,me2){
	if (me.style.display==""){
		me.style.display="inline";
		me2.style.display="";
	}else{
		me.style.display="";
		me2.style.display="inline";
	}
}
