Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
Re: Delete row from mysql only deletes the contents?
You need to look at your SQL statement
$sql = "DELETE FROM cart WHERE ItemId='$ItemId'";
$result = mysql_query($sql);
if(! $result || mysql_error() || mysql_num_affected_rows() < 1)
echo "An error has occured [$sql] : " . mysql_error();
echo "Elvis has left the building, or we have deleted your item from the
You'll probably find that $ItemId is not populated.
- » ** ONLINE DATA INSERT --> MYSQL front & PHP script **
- — Next thread in » PHP Scripting Forum