timezone() public static method

Return a DateTimeZone object based on the current timezone.
public static timezone ( mixed $timezone = null ) : DateTimeZone
$timezone mixed
return DateTimeZone
Beispiel #1
0
 public function testTimezone()
 {
     isClass('\\DateTimeZone', Dates::timezone());
     $dtz = new DateTimeZone('America/Los_Angeles');
     same($dtz, Dates::timezone($dtz));
 }