Code: Select all
$sql = mysql_query("INSERT INTO courses (location, course, instructor, blurb, description) VALUES ('$location', '$class', '$teacher', '$blurb', '$description'");
if(!$sql) {
echo "Sorry there was a problem adding that class due to the following error:";
echo "<br />- " .mysql_error();
echo "<br />" .$teacher;
echo "<br />" .$class;
echo "<br />" .$location;
echo "<br />" .$blurb;
echo "<br />" .$description;
exit();
}
please please please help me on this one, I am losing my mind as I can't see the error and the mysql_error() isn't helpfull at all. Thank you again,Sorry there was a problem adding that class due to the following 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 '' at line 1
Mary Mezinis
Amazing English
classroom
this is just a test course to see if the add script is working.
Please do not try to sign up for this class, it is just a test to see if the add script is working properly.