I have a test db names "Customers" and a test table named "test" which contains 2 fields. ID which is auto increment and Name which is varchar 20. When I do a hard coded insert
$name = "Will"
echo $name; // this echo works
$db = mysql_connect('localhost', 'user', 'pass','Customers');
echo $name; // this echo works also
the insert will work. When I try to insert from a form
$name = $_POST['name'];
echo $name; // this echo works
$db = mysql_connect('localhost', 'user', 'pass','Customers');
echo $name; // this echo is never reached;
this method does not work and won't give me any errors. Error outputting is on because when I put in botched data when hard coding I can echo errors to the page.
I did not post the code that is doing the insert because it is not hitting any lines after I connect to the db when using form input. So I think for the moment posting my insert code would be irrelevant.
$name = "Will"
echo $name; // this echo works
$db = mysql_connect('localhost', 'user', 'pass','Customers');
echo $name; // this echo works also
the insert will work. When I try to insert from a form
$name = $_POST['name'];
echo $name; // this echo works
$db = mysql_connect('localhost', 'user', 'pass','Customers');
echo $name; // this echo is never reached;
this method does not work and won't give me any errors. Error outputting is on because when I put in botched data when hard coding I can echo errors to the page.
I did not post the code that is doing the insert because it is not hitting any lines after I connect to the db when using form input. So I think for the moment posting my insert code would be irrelevant.