I'm asking about PHP contants for timezones name
For Example :
$rc = date_default_timezone_set("US/Mountain");
"US/Mountain"
to be constants not write it as text
is it exist from PHP classes or I need to do it myself
Thanks in advance
I'm asking about PHP contants for timezones name
For Example :
$rc = date_default_timezone_set("US/Mountain");
"US/Mountain"
to be constants not write it as text
is it exist from PHP classes or I need to do it myself
Thanks in advance
There's no such a thing as a predefined constant for this because simply it's not needed. date_default_timezone_set
works with a string. If you want a constant then you can define one yourself:
define('MY_CONSTANT', "US/Mountain");
and obviously use it as:
date_default_timezone_set(MY_CONSTANT);