INSERT INTO error MYSQL/PHP

Posted by bat on Stack Overflow See other posts from Stack Overflow or by bat
Published on 2010-05-26T05:11:04Z Indexed on 2010/05/26 5:21 UTC
Read the original article Hit count: 263

Filed under:
|

I get this 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 'order (total, addy, cc) VALUES ('798' , '123 sadf' , '12124123')' at line 1

$total = addslashes(($_SESSION['total']));

$addy = addslashes(($_POST['addy']));

$cc = addslashes(($_POST['cc']));

echo "$total";

echo "$addy";

echo "$cc";

mysql_query("INSERT INTO order (total, addy, cc) VALUES ('$total' , '$addy' , '$cc')") or die(mysql_error());

help plz =]

© Stack Overflow or respective owner

Related posts about php

Related posts about mysql