DateTimeZone::__construct
DateTimeZone::__construct - Creates new DateTimeZone object
Manual
timezone_open(
string$timezone ): DateTimeZone|false
Creates new DateTimeZone object.
Parameters
- timezone
-
One of the supported timezone names or an offset value (+0200).
Return Values
Returns DateTimeZone on success. Procedural style returns false on failure.
Exceptions and Errors
This method throws Exception if the timezone supplied is not recognised as a valid timezone.