////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////
function updatecart(val)
{
	//$container["p".$_POST["srno"]]["code"] = $_POST["pcode"]; 
//	$container["p".$_POST["srno"]]["pid"] = $_POST["srno"];
//	$container["p".$_POST["srno"]]["fabric"] = $_POST["pfabric"];
//	$container["p".$_POST["srno"]]["count"] = 1;
//	$container["p".$_POST["srno"]]["price"] = $_POST["pprice"];
//	$container["p".$_POST["srno"]]["user"] = $_SESSION["py_user_id"];
//	$container["p".$_POST["srno"]]["type"] = $_POST["ptypename"];
//	$container["p".$_POST["srno"]]["aweight"]=$_POST["ptypename"];
//	
	//var pid document.getElementById("").value;
	xmlHttp=GetXmlHttpObject()
	var url="updatecart.php?srno="+val;
	xmlHttp.onreadystatechange=show_updated_cart;
	xmlHttp.open("GET",url,true)
	xmlHttp.send(null)
}
function show_updated_cart() 
{ 
if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
 { 
 	try{
	alert("Cart Updated Successfully");
	self.location="showcart.php";	
 	//document.getElementById('DivProductPrice').innerHTML=xmlHttp.responseText
	}catch(ex){}
 } 
}

function GetXmlHttpObject()
{
var xmlHttp=null;
try
 {
 // Firefox, Opera 8.0+, Safari
 xmlHttp=new XMLHttpRequest();
 }
catch (e)
 {
 //Internet Explorer
 try
  {
  xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
  }
 catch (e)
  {
  xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
  }
 }
return xmlHttp;
}
