dropdownbox - how to insert three dropdown valuein one field in to database -
How can I add a date of birth to three dropdown values in my database to my database? Am I correcting $ dob or is not it? Please help me
My form
& lt; Form name = "" id = "order-form" class = "smart-form" role = "form" verb = "" method = "post" enactepe = "multipart / form-data" & gt; & Lt; TR & gt; & Lt; Td> & Lt; Font color = "# 334D66" & gt; Date of Birth: & lt; / Td> & Lt; Td> & Lt; Select name = "birthday" & gt; & Lt; Option selected & gt; & Lt; / Options & gt; & Lt; Options & gt; 01 & lt; / Options & gt; & Lt; Options & gt; 02 & lt; / Options & gt; . . & Lt; / Select & gt; & Lt; Select name = "birthmate" & gt; & Lt; Option selected & gt; & Lt; / Options & gt; & Lt; Option & gt; January & lt; / Options & gt; & Lt; Option & gt; February & lt; / Options & gt; . . & Lt; / Select & gt; & Lt; Select name = "birthday" & gt; & Lt; Option selected & gt; & Lt; / Options & gt; & Lt; Options & gt; 1999 & lt; / Options & gt; & Lt; Options & gt; 1998 & lt; / Options & gt; . . & Lt; / Select & gt; & Lt; / TD & gt; & Lt; / TR & gt; And enter my code like this
$ _POST ['address'], 'city' => $ _POST ['city_ $'] ['province_id'], 'postcode' = & gt; _POST ['Postcode'], 'country_id' => $ _POST ['country_id'], 'phone' = & gt $ _POST ['phone'], 'dub' => $ dob, 'gender' = & $ _POST ['gender'], 'business' => $ _POST ['business'], 'fav_quotes' = $ _POST ['fav_quotes'], 'news' = & gt; $ _POST ['news' ], 'Newsletter' = & gt; $ _POST ['newsletter'], 'reg_type_id' => $ reg_type_id, 'images' = & gt; $ _POST ['image']); insert ('user', $ Data); // resonance "success"; header ("location: paypal-invoice / bundend.example.fpp"); }? & Gt; Thanks in advance.
You accept Mysql dababase because mysql yyyy-mm-dd format so that you
needs $ year. '-'. $ Month. '-' $ Day I think this will work for you
Comments
Post a Comment