<?php
	session_start();
	require_once 'db_connection.php';
	//$dis = 0; 
	$tempid = $_POST['tempid'];
	//$pro_dis = $_POST['pro_dis'];
	$name = $_POST['name'];
	//$user_id = $_SESSION['user_id'];
	//$price = $_POST['price'];

	//$dis = $pro_dis * $qty;

	//$result = mysqli_query($conn, "SELECT * FROM mobiletemporarycart WHERE tempid='$tempid'");
	//$rw = mysqli_fetch_array($result);

	//$pro_price = $rw['pro_price'];

	//$proid = $rw['proid'];

	//$products = mysqli_query($conn, "SELECT * FROM mobileproducts WHERE prid ='$proid'");
	//$prinfo = mysqli_fetch_array($products);

	//$productprice = $prinfo['sellprice'];

	//$qprice = $amount / $productprice;
	//$price = $qty * $productprice;


	

		$sql3 = "UPDATE mobiletemporarycart SET pro_name ='$name' WHERE tempid='$tempid'";
		if ($conn->query($sql3) === TRUE) {
			echo "1";
		}else{
			echo 0;
		}




	?>
