function brows_check(){
	if (navigator.userAgent.indexOf("Firefox")!=-1){
		return "ff";
	}else if (navigator.userAgent.indexOf("MSIE")!=-1){
		return "ie";
	}
	
}

function show_msg(el, msg)
{
	document.getElementById(el).innerHTML=msg;
	setTimeout("hide_msg('msg')", 5000);
}

function hide_msg(id)
{
	document.getElementById(id).innerHTML="";
}


/* Functions */
function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
function ltrim(stringToTrim) {
	return stringToTrim.replace(/^\s+/,"");
}
function rtrim(stringToTrim) {
	return stringToTrim.replace(/\s+$/,"");
}

function trimWSCharEntity(str)
{
return (
str.replace(/^(\s|&nbsp;)+/g, "").replace(/(\s|&nbsp;)+$/g, ""));
}



function GetXmlHttpObject()
{ 
	var objXMLHttp=null
	if (window.XMLHttpRequest)
	{
		objXMLHttp=new XMLHttpRequest()
	}
	else if (window.ActiveXObject)
	{
		objXMLHttp=new ActiveXObject("Microsoft.XMLHTTP")
	}

	return objXMLHttp
} 

 


 
 
 
  /* ################################################  add to Cart  ######################################### */ 
 
function stateChanged() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("msg").innerHTML="Sending Request...";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		var dumy = xmlHttp.responseText;
		//alert(dumy);
		var res = dumy.split("###");
		
		//document.getElementById("msg").innerHTML=res[0];		

		if(res[1] == "yes")
		{
			//parent.parent.show_msg("msg",res[0]);
			load_page2('cartDiv', 'includes/cart_script.php', '&1=1')
			$.jGrowl('<div class=\'alert\'><b>Item has been added to your Shopping Cart</b></div>');
		}
		
		//setTimeout("hide_msg('addcomp')", 8000);

		//alert(dumy);
	}
	
}  
 

function add_to_cart( pid )
{
	//var pid = document.getElementById('pid').value;
	if(pid == "")
	{
		alert('select an item to proceed');
		return false;
	}
	var pt1 = document.getElementById('pt1');
	var pt2 = document.getElementById('pt2');
	
	if( pt1.checked == true){
		var price_type = pt1.value;
	}else if( pt2.checked == true){
		var price_type = pt2.value;
	}
	
	//return false;
	
	<!-- ########## star form posting ######### -->
	
		xmlHttp=GetXmlHttpObject()
		if (xmlHttp==null)
		{
			alert ("Browser does not support HTTP Request")
			return
		} 
		if(brows_check() == "ie"){
			var fChk = false;
		}else if(brows_check() == "ff"){
			var fChk = true;
		}
			xmlHttp.onreadystatechange=stateChanged;
			xmlHttp.open("POST","scripts/add_to_cart_ajax.php",fChk)
		 // Set our POST header correctly…
		var params="pid="+pid+"&price_type="+price_type;
		//alert(params); return false;
		  
		  xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
		  xmlHttp.setRequestHeader("Content-length", params.length);
		  xmlHttp.setRequestHeader("Connection", "close");
		
		  // Send the parms data…
		  xmlHttp.send(params);
 }
 
  /* ################################################   end  ######################################### */
 
 
 
 
 
 
 /* ################################################  Delete cart item  ######################################### */ 
 
function stateChanged3() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("msg").innerHTML="Sending Request...";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		var dumy = xmlHttp.responseText;
		//alert(dumy);
		var res = dumy.split("###");
		
		//document.getElementById("msg").innerHTML=res[0];		

		if(res[1] == "yes")
		{
			//parent.parent.show_msg("msg",res[0]);
			load_page2('mainCart', 'includes/cart.php', '&1=1')
			$.jGrowl('<div class=\'alert\'><b>Item(s) removed successfully</b></div>');
		}
		
		//setTimeout("hide_msg('addcomp')", 8000);

		//alert(dumy);
	}
	
}  
 

function update_cart(form)
{
	var f = document.uc;
	//var f = document.getElementById(form);
	var ids = f.remove;
	var idsArray = new Array();

	for(var i=0; i<ids.length; i++)
	{
		if(f.remove[i].checked == true)
		{
			idsArray.push(f.remove[i].value);
		}
	}
	
	if( ids.length == 'undefined' || ids.length == undefined )
	{
		if(f.remove.value != "" && f.remove.checked == true){
			idsArray.push(f.remove.value);
		}
	}

	if(idsArray == "" || idsArray == "undefined" || idsArray == undefined)
	{
		alert("Please select at least one item to remove");
		return false;
	}
	
	if( !confirm('Are you sure you want to remove selected item(s)?') )
	{
		return false;
	}
	//alert(idsArray);
	
	<!-- ########## star form posting ######### -->
	
		xmlHttp=GetXmlHttpObject()
		if (xmlHttp==null)
		{
			alert ("Browser does not support HTTP Request")
			return
		} 
		if(brows_check() == "ie"){
			var fChk = false;
		}else if(brows_check() == "ff"){
			var fChk = true;
		}
			xmlHttp.onreadystatechange=stateChanged3;
			xmlHttp.open("POST","scripts/update_cart.php",fChk)
		 // Set our POST header correctly…
		var params="pid="+idsArray+"&act=del";
		  
		//alert(params); return false;
		  
		  xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
		  xmlHttp.setRequestHeader("Content-length", params.length);
		  xmlHttp.setRequestHeader("Connection", "close");
		
		  // Send the parms data…
		  xmlHttp.send(params);
 }
 
  /* ################################################   end  ######################################### */ 
 
 
 
 
 
 
 
 
 
 
  /* ################################################  Empty Cart  ######################################### */ 
 
function stateChanged5() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("msg").innerHTML="Sending Request...";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		var dumy = xmlHttp.responseText;
		//alert(dumy);
		var res = dumy.split("###");
		
		//document.getElementById("msg").innerHTML=res[0];		

		if(res[1] == "yes")
		{
			//parent.parent.show_msg("msg",res[0]);
			load_page2('mainCart', 'includes/cart.php', '&1=1')
			$.jGrowl('<div class=\'alert\'><b>Your cart is Empty!</b></div>');
		}
		
		//setTimeout("hide_msg('addcomp')", 8000);

		//alert(dumy);
	}
	
}  
 

function empty_cart()
{
	
	if( !confirm('Are you sure you want to remove all items from your cart?') )
	{
		return false;
	}
	
	<!-- ########## star form posting ######### -->
	
		xmlHttp=GetXmlHttpObject()
		if (xmlHttp==null)
		{
			alert ("Browser does not support HTTP Request")
			return
		} 
		if(brows_check() == "ie"){
			var fChk = false;
		}else if(brows_check() == "ff"){
			var fChk = true;
		}
			xmlHttp.onreadystatechange=stateChanged5;
			xmlHttp.open("POST","scripts/update_cart.php",fChk)
		 // Set our POST header correctly…
		var params="act=empty";
		  
		//alert(params); return false;
		  
		  xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
		  xmlHttp.setRequestHeader("Content-length", params.length);
		  xmlHttp.setRequestHeader("Connection", "close");
		
		  // Send the parms data…
		  xmlHttp.send(params);
 }
 
  /* ################################################   end  ######################################### */ 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 /* ################################################  Update quantity  ######################################### */ 
 
function stateChanged4() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("msg").innerHTML="Sending Request...";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		var dumy = xmlHttp.responseText;
		//alert(dumy);
		var res = dumy.split("###");
		
		//document.getElementById("msg").innerHTML=res[0];		

		if(res[1] == "yes")
		{
			//parent.parent.show_msg("msg",res[0]);
			load_page2('mainCart', 'includes/cart.php', '&1=1')
			$.jGrowl('<div class=\'alert\'><b>Qty Updated successfully</b></div>');
		}
		
		//setTimeout("hide_msg('addcomp')", 8000);

		//alert(dumy);
	}
	
}  
 

function update_quantity(id, val)
{
	
	<!-- ########## star form posting ######### -->
		
	xmlHttp=GetXmlHttpObject()
	if (xmlHttp==null)
	{
		alert ("Browser does not support HTTP Request")
		return
	} 
	if(brows_check() == "ie"){
		var fChk = false;
	}else if(brows_check() == "ff"){
		var fChk = true;
	}
		xmlHttp.onreadystatechange=stateChanged4;
		xmlHttp.open("POST","scripts/update_cart.php",fChk)
	 // Set our POST header correctly…
	var params="id="+id+"+&val="+val+"&act=quantity";
	  
	//alert(params); return false;
	  
	  xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
	  xmlHttp.setRequestHeader("Content-length", params.length);
	  xmlHttp.setRequestHeader("Connection", "close");
	
	  // Send the parms data…
	  xmlHttp.send(params);
 }
 
  /* ################################################   end  ######################################### */  
 
 
 
 
 
 
 
 
 
/* ################################################  Do Vote  ######################################### */ 
 
function stateChanged6() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("msg").innerHTML="Sending Request...";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		var dumy = xmlHttp.responseText;
		//alert(dumy);
		var res = dumy.split("###");
		
		//document.getElementById("msg").innerHTML=res[0];		

		if(res[1] == "yes")
		{
			//parent.parent.show_msg("msg",res[0]);
			//document.getElementById('pollDiv').innerHTML = '';
			setTimeout( load_page2('pollDiv', 'scripts/polls.php', '&act=result'), 15000);
			//$.jGrowl('<div class=\'alert\'><b>You have successfully casted your vote</b></div>');
		}
		if(res[1] == "no")
		{
			//parent.parent.show_msg("msg",res[0]);
			$.jGrowl('<div class=\'alert\'><b>You have already casted your vote for this poll</b></div>');
		}
		
		//setTimeout("hide_msg('addcomp')", 8000);

		//alert(dumy);
	}
	
}  
 

function doVote()
{
	var f = document.pollsForm;
	var oid = "";
	for( var i=0; i<f.option.length; i++)
	{
		if( f.option[i].checked == true )
		{
			oid = f.option[i].value;
		}
	}
	
	if( oid == "" )
	{
		alert("Select an option to vote for");
		return false;
	}
	var poll_id = f.poll_id.value;
	
	<!-- ########## star form posting ######### -->
		
	xmlHttp=GetXmlHttpObject()
	if (xmlHttp==null)
	{
		alert ("Browser does not support HTTP Request")
		return
	} 
	if(brows_check() == "ie"){
		var fChk = false;
	}else if(brows_check() == "ff"){
		var fChk = true;
	}
		xmlHttp.onreadystatechange=stateChanged6;
		xmlHttp.open("POST","scripts/do_vote.php",fChk)
	 // Set our POST header correctly…
	var params="oid="+oid+"+&poll_id="+poll_id+"&act=vote";
	
	//alert(params); return false;
	  
	  xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
	  xmlHttp.setRequestHeader("Content-length", params.length);
	  xmlHttp.setRequestHeader("Connection", "close");
	
	  // Send the parms data…
	  xmlHttp.send(params);
 }
 
  /* ################################################   end  ######################################### */ 
 
 
 
 
 
 



/* ################################################  Add to wishlist  ######################################### */ 
 
function stateChanged7() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("msg").innerHTML="Sending Request...";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		var dumy = xmlHttp.responseText;
		//alert(dumy);
		var res = dumy.split("###");
		
		//document.getElementById("msg").innerHTML=res[0];		

		if(res[1] == "yes")
		{
			//parent.parent.show_msg("msg",res[0]);
			//load_page2('pollDiv', 'scripts/polls.php', '&act=result');
			$.jGrowl('<div class=\'alert\'><b>'+res[2]+'</b></div>');
		}
		if(res[1] == "no")
		{
			//parent.parent.show_msg("msg",res[0]);
			$.jGrowl('<div class=\'alert\'><b>'+res[2]+'</b></div>');
		}
		
		//setTimeout("hide_msg('addcomp')", 8000);

		//alert(dumy);
	}
	
}  
 

function add_to_wishlist(pid)
{
	<!-- ########## star form posting ######### -->
	xmlHttp=GetXmlHttpObject()
	if (xmlHttp==null)
	{
		alert ("Browser does not support HTTP Request")
		return
	} 
	if(brows_check() == "ie"){
		var fChk = false;
	}else if(brows_check() == "ff"){
		var fChk = true;
	}
		xmlHttp.onreadystatechange=stateChanged7;
		xmlHttp.open("POST","scripts/add_to_wishlist.php",fChk)
	 // Set our POST header correctly…
	var params="pid="+pid+"&act=add";
	  
	//alert(params); return false;
	  
	  xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
	  xmlHttp.setRequestHeader("Content-length", params.length);
	  xmlHttp.setRequestHeader("Connection", "close");
	
	  // Send the parms data…
	  xmlHttp.send(params);
 }
 
  /* ################################################   end  ######################################### */ 





/* ################################################  Remove from wishlist  ######################################### */ 
 
function stateChanged8() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("msg").innerHTML="Sending Request...";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		var dumy = xmlHttp.responseText;
		var res = dumy.split("###");
		
		//document.getElementById("msg").innerHTML=res[0];		

		if(res[1] == "yes")
		{
			//parent.parent.show_msg("msg",res[0]);
			//load_page2('pollDiv', 'scripts/polls.php', '&act=result');
			$.jGrowl('<div class=\'alert\'><b>'+res[2]+'</b></div>');
			window.location.reload();
		}
		if(res[1] == "no")
		{
			//parent.parent.show_msg("msg",res[0]);
			$.jGrowl('<div class=\'alert\'><b>'+res[2]+'</b></div>');
		}
		
		//setTimeout("hide_msg('addcomp')", 8000);

		//alert(dumy);
	}
	
}  
 

function remove_from_wishlist(wid)
{
	if(!confirm('Are you sure you want to remove this item from your wishlist'))
	{
		return false;
	}
	
	<!-- ########## star form posting ######### -->
	xmlHttp=GetXmlHttpObject()
	if (xmlHttp==null)
	{
		alert ("Browser does not support HTTP Request")
		return
	} 
	if(brows_check() == "ie"){
		var fChk = false;
	}else if(brows_check() == "ff"){
		var fChk = true;
	}
		xmlHttp.onreadystatechange=stateChanged8;
		xmlHttp.open("POST","scripts/add_to_wishlist.php",fChk)
	 // Set our POST header correctly…
	
	var params="wid="+wid+"&act=remove";
	  
	//alert(params); return false;
	  
	  xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
	  xmlHttp.setRequestHeader("Content-length", params.length);
	  xmlHttp.setRequestHeader("Connection", "close");
	
	  // Send the parms data…
	  xmlHttp.send(params);
 }
 
/* ################################################   end  ######################################### */ 




/* ################################################   get sub cats  ######################################### */ 

function stateChanged9() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("ind").style.display="inline";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("ind").style.display="inline";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("ind").style.display="inline";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		//document.getElementById("ind").style.display="none";
		var dumy = xmlHttp.responseText;
		//document.getElementById("sbCats").innerHTML=dumy;
		//alert(dumy);
		
		var opts = dumy.split("_");
		document.getElementById("brand_id").disabled =false;	
		
		var theDropDown = document.getElementById("brand_id")
		var numberOfOptions = theDropDown.options.length
		for (i=0; i<numberOfOptions; i++) 
		{
			//Note: Always remove(0) and NOT remove(i)
			theDropDown.remove(0)
		}
		
		for(var i=0; i<opts.length-1; i++ ){
			var opts_value = opts[i].split(",");
			document.getElementById("brand_id").options[i] =new  Option(opts_value[1],opts_value[0]);
		}
		
	}
	
}  
 

function getSubCats()
{
	var form = document.add;
	if(form.category_id.value !="")
	{
		var catid = form.category_id.value;
		<!-- ########## star form posting ######### -->
		xmlHttp=GetXmlHttpObject()
		if (xmlHttp==null)
		{
			alert ("Browser does not support HTTP Request")
			return
		} 

		//alert(url);
		//return false();
		//url=url+str
		if(brows_check() == "ie"){
			var fChk = false;
		}else if(brows_check() == "ff"){
			var fChk = true;
		}
		xmlHttp.onreadystatechange=stateChanged9;
		xmlHttp.open("POST","scripts/subcats.php",fChk)
		// Set our POST header correctly…
		var params = "catid="+catid;
		//alert(params);
		
		xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
		xmlHttp.setRequestHeader("Content-length", params.length);
		xmlHttp.setRequestHeader("Connection", "close");
		  // Send the parms data…
		 xmlHttp.send(params);
	}else{
		form.brand_id.disabled =true;	
	}
 }

/* ################################################   end  ######################################### */ 







/* ################################################   Compare  ######################################### */ 

function stateChanged10() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("ind").style.display="inline";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("ind").style.display="inline";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("ind").style.display="inline";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		//document.getElementById("ind").style.display="none";
		var dumy = xmlHttp.responseText;
		//alert(dumy);
		var res = dumy.split("###");
		if(res[1] == "yes")
		{
			$.jGrowl('<div class=\'alert\'><b>Item has been added to compare list</b></div>');
			load_page2('compare_main', 'includes/compare.php', '&1=1');
		}
		else if(res[1] == "no")
		{
			alert(res[2]);
		}
		
	}
	
}  
 

function add_to_compare(id, act)
{
	if( id != "" )
	{
		<!-- ########## star form posting ######### -->
		xmlHttp=GetXmlHttpObject()
		if (xmlHttp==null)
		{
			alert ("Browser does not support HTTP Request")
			return
		} 

		//alert(url);
		//return false();
		//url=url+str
		if(brows_check() == "ie"){
			var fChk = false;
		}else if(brows_check() == "ff"){
			var fChk = true;
		}
		xmlHttp.onreadystatechange=stateChanged10;
		xmlHttp.open("POST","scripts/compare_data.php",fChk)
		// Set our POST header correctly…
		var params = "pid="+id+"&act="+act;
		//alert(params);
		
		xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
		xmlHttp.setRequestHeader("Content-length", params.length);
		xmlHttp.setRequestHeader("Connection", "close");
		  // Send the parms data…
		 xmlHttp.send(params);
	}
	else
	{
		// nothing :-)
	}
 }

/* ################################################   end  ######################################### */ 






  /* ################################################  add to Download  ######################################### */ 
 
function stateChanged12() 
{ 
	if(xmlHttp.readyState==1){
		//document.getElementById("msg").innerHTML="Sending Request...";
	}
	if(xmlHttp.readyState==2){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if(xmlHttp.readyState==3){
		//document.getElementById("msg").innerHTML="Loading Data...";
	}
	if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete" || xmlHttp.readyState==0)
	{ 
		//DataLd();
		var dumy = xmlHttp.responseText;
		//alert(dumy);
		var res = dumy.split("###");
		
		//document.getElementById("msg").innerHTML=res[0];		

		if(res[1] == "yes")
		{
			window.location.href="order_view.php";
		}
		else
		{
			$.jGrowl('<div class=\'alert\'>'+res[1]+'</div>');
		}
		
		//setTimeout("hide_msg('addcomp')", 8000);

		//alert(dumy);
	}
	
}  
 

function add_to_download( pid )
{
	//var pid = document.getElementById('pid').value;
	if(pid == "")
	{
		alert('select an item to proceed');
		return false;
	}
	var pt1 = document.getElementById('pt1');
	var pt2 = document.getElementById('pt2');
	
	if( pt1.checked == true){
		var price_type = pt1.value;
	}else if( pt2.checked == true){
		var price_type = pt2.value;
	}
	
	<!-- ########## star form posting ######### -->
	
		xmlHttp=GetXmlHttpObject()
		if (xmlHttp==null)
		{
			alert ("Browser does not support HTTP Request")
			return
		} 
		if(brows_check() == "ie"){
			var fChk = false;
		}else if(brows_check() == "ff"){
			var fChk = true;
		}
			xmlHttp.onreadystatechange=stateChanged12;
			xmlHttp.open("POST","scripts/add_to_download.php",fChk)
		 // Set our POST header correctly…
		var params="pid="+pid+"&price_type="+price_type;
		//alert(params); return false;
		  
		  xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
		  xmlHttp.setRequestHeader("Content-length", params.length);
		  xmlHttp.setRequestHeader("Connection", "close");
		
		  // Send the parms data…
		  xmlHttp.send(params);
 }
 
  /* ################################################   end  ######################################### */
