What's wrong with this php/mysql?

Joe Burnett

New member
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 'Alltel") { $To = "$_POST['num']@message.alltel.com"; ' at line 2Error adding form to mysql database!

** I put \ before the double quotes which is what is used in the insert into query.
<?php
if(\$_POST['car'] == \"Alltel\")
{
\$To = \"\$_POST['num']@message.alltel.com\";
}
if(\$_POST[\'car\'] == \"AT&T\")
{
\$To1 = \"\$_POST['num']@txt.att.net\";
\$To2 = \"\$_POST['num']@mms.att.net\";
}
 
Back
Top