Converting Date Form Fields
| From: | Zach Curtis | Date: | Fri, 16 Nov 2001 16:01:53 +0000 |
| Subject: | Converting Date Form Fields | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-14401@lists.php.net to get a copy of this message | ||
I have two HTML form fields birthMonth (e.g., Jan=1, Feb=2...) and birthYear
(e.g., 2001=2001, 1999=1999...). How can take these two individual form
fields, then add in a default value of "1" for the birthDay (this is not
asked in the form), and put this data into a MySQL table field birthDate
with field type DATE (YYYY-MM-DD)? The part I do not know how to accomplish
is taking these form fields and then combining them into a date
field/format.
Thank you.
Zach Curtis
POPULUS