Jump to content

mktime help


taith

Recommended Posts

i'm pretty sure this is mktime that does this... anybody know how to translate... say day/month into a date(z) type format?

 

 

mktime() returns a timestamp based on the parameters, dates second parameter is a timestamp so the below should work just fine.

 

date("d-m-Y", mkdate());

 

if you were referring to date(z) as in date('z') just do date("z", mkdate())

 

Link to comment
https://forums.phpfreaks.com/topic/49831-mktime-help/#findComment-244421
Share on other sites

if the date is in an english language format, you can use strtotime() which will return a timestamp that you can use with date().  otherwise, yes, mktime() does this using numerical values.  see the manual for the parameters:

 

http://ca3.php.net/manual/en/function.mktime.php

Link to comment
https://forums.phpfreaks.com/topic/49831-mktime-help/#findComment-244435
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.