I’m using this code to get my post data into my database
$sql="INSERT INTO nproducts (title, ref, desc, imgloc, keywords, price)
VALUES
('$_POST[title]','','$_POST[dec]','$_POST[imgloc]','$_POST[keywords]','$_POST[price]')";
but im getting this error msg, ref is set as auto inc, do I even need to include this with the insert? I have tried with and without it but same problem.
Error: 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 'desc, imgloc, keywords, price) VALUES ('Oven34','','Variables are one of the cor' at line 1
be helpful if someone can point me in the right direction, I’m not sure how to find out where my problem lies.