var xmlhttp
function showCustomer(str){
	xmlhttp=GetXmlHttpObject();
	if (xmlhttp==null){
	  alert ("Your browser does not support AJAX!");
	  return;
	 }
	var url="http://www.microforum.ca/action.asp";
	url=url+"?q="+str;
	url=url+"&sid="+Math.random();
	xmlhttp.onreadystatechange=stateChanged;
	xmlhttp.open("GET",url,true);
	xmlhttp.send(null);
}

function stateChanged(){
	if (xmlhttp.readyState==4){
	  document.getElementById("txtHint").innerHTML=xmlhttp.responseText;
	}
}

function GetXmlHttpObject(){
	if (window.XMLHttpRequest){
	  return new XMLHttpRequest();
	  }
	if (window.ActiveXObject){
	  return new ActiveXObject("Microsoft.XMLHTTP");
	  }
	return null;
}

function PreviousPage(){
  history.back(1);
}

function rotate(count) {
	if (count==2){
		document.getElementById('selad1').style.display='none';
		document.getElementById('selad2').style.display='block';
	}else{
		document.getElementById('selad1').style.display='block';
		document.getElementById('selad2').style.display='none';
	}
	count++;
	if (count>3) {count = 1}
	t=setTimeout ("rotate("+count+")", 4000);
}

function seladd(divnm){
	if (divnm==2){
		document.getElementById('selad1').style.display='none';
		document.getElementById('selad2').style.display='block';
	}else{
		document.getElementById('selad1').style.display='block';
		document.getElementById('selad2').style.display='none';
	}
	clearTimeout(t);
	rotate(divnm);
}


function shwSubnav(bid){
	document.getElementById(bid).style.display='block';
}

function disSubnav(bid){
	document.getElementById(bid).style.display='none';
}
