Hi:
I am confused with the date field. I have the following html code for a birthdate, and I want to same it to a date field in a table:
<td>Birth Date: <input type="text" name="birthdate" size="8" maxlength="8"> ex. 19910101</td
....
mysql_query("INSERT INTO studentname (birthdate) values ('$_POST[birthdate]')";
Now I got error saying:
Error: Incorrect date value: '20000212'
Please help to fix it. Should I do some conversion? How do I do it?
Thank you for your help.
I am confused with the date field. I have the following html code for a birthdate, and I want to same it to a date field in a table:
<td>Birth Date: <input type="text" name="birthdate" size="8" maxlength="8"> ex. 19910101</td
....
mysql_query("INSERT INTO studentname (birthdate) values ('$_POST[birthdate]')";
Now I got error saying:
Error: Incorrect date value: '20000212'
Please help to fix it. Should I do some conversion? How do I do it?
Thank you for your help.
Comment