> I am wanting one field on a table in one of my MYSQL databases to
contain
> different dates and times as a epoch timestamps.
>
> Firstly how do I convert a particular time and date which the user
will
> enter on the website into the epoch timestamp.
$db_timestamp = strtotime($user_input);
> A
If you'd bothered to RTFM, you'd know both answers already. strtotime()
for number one, and date() accepts an optional second argument (the
timestamp).
Ian Gray wrote:
I am wanting one field on a table in one of my MYSQL databases to contain different dates and times as a epoch timestamps.
Fi
Ian Gray wrote:
I am wanting one field on a table in one of my MYSQL databases to contain different dates and times as a epoch timestamps.
You're better off storing as a DATETIME field -- it has limits from
1000-01-01 to -12-31, instead of 1970 to 2037..
Firstly how do I convert a particular
3 matches
Mail list logo