MySQL Forums
Forum List  »  PHP

Re: issue getting dates on form + adding to database
Posted by: John C. Clair
Date: February 07, 2017 05:19AM

PHP'S date needs a timestamp as second parameter .If $insertdate isn't one it won't work you can though get a timestamp from string using PHP's strtotime function.
Also the value in your sql statement must be formatted according to the type used in your mysql database for example date,datetime or timestamp.

Options: ReplyQuote


Subject
Written By
Posted
Re: issue getting dates on form + adding to database
February 07, 2017 05:19AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.