What Have I Done Wrong ?
$addedby=$_SESSION['id'];
$text="Subject: I want to add a New Phone Name :$name Address :$address Phone :$phone Category :$category Email :$email Website :$website Details :$details";
$sql = "INSERT INTO messages SET text='$text' , from='$addedby'";
mysql_query($sql) or die('Website Under Maintanance '.mysql_error());
The Id is integer and the from is varchar(30)
.
Please Tell Me what have I done wrong ?
The Error Is :
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='1'