I have been checking my syntax all night yet I can't seem to see what is wrong. I'm relatively new to all this and would appreciate nay help that may be provided. The error I'm getting 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 ''ID','Name','Option','Sides') VALUES(NULL,'Denise','Chicken','Mashed Potat' at line 1"
My code is below:
<?php
include 'connect.php';
$name = $_POST['inputName'];
$opt = $_POST['inputOption'];
$side = $_POST['inputSides'];
if(!$_POST['Submit']) {
echo "Please fill out the form.";
header('Location: index.php');
} else {
mysql_query("INSERT INTO people ('ID','Name','Option','Sides')
VALUES(NULL,'$name','$opt','$side')") or die(mysql_error());
echo "User has been added.";
header('Location: index.php');
}
?>