location.href='".$_SERVER['PHP_SELF']."'; "; } if(isset($_POST['checkout'])){ $sql = "select * from shoppingcart where shoppingcart.flag >= ".$flagarray[0]." and shoppingcart.sessionid = '".session_id()."' order by shoppingcart.shoppingid"; $result = select_data_func($sql); $count = 0; while($row = mysql_fetch_array( $result)){ if($_POST['qty'.$row['shoppingid']] <> $row['qtyorder']){ $sql = "update shoppingcart set qtyorder = ".$_POST['qty'.$row['shoppingid']]." where flag = '".$flagarray[0]."' and shoppingid = ".$row['shoppingid']; $shoppingcartid = manage_data_func($sql); } $count++; } if($count > 0){ echo ""; exit; }else{ echo ""; } } ?>