Jump to content

[SOLVED] Deleting items


pwes24

Recommended Posts

I have a simple code that just doesnt work. Can you help me point out the problem? Thank you.

 

$prod_id = $_GET['product_id'];
$query = "DELETE * FROM `shoppingcart` WHERE `pro_id`='".$prod_id."' ";

 

Here's the error it gives me:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '* FROM `shoppingcart` WHERE `pro_id`='1'' at line 1

Link to comment
https://forums.phpfreaks.com/topic/89844-solved-deleting-items/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.