Jump to content

[SOLVED] time() to date()?


Chevy

Recommended Posts

It defaults to current time stamp even if you don't pass the second argument for the date function.

If you want to pass specified time stamp , you can use

mktime ( [int hour [, int minute [, int second [, int month [, int day [, int year [, int is_dst]]]]]]] 

like

echo date("M-d-Y", mktime(0, 0, 0, 12, 32, 1997));

Link to comment
https://forums.phpfreaks.com/topic/55597-solved-time-to-date/#findComment-274684
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.