PHP timezone_location_get() 函數

實例

返回指定時區的位置信息:

<?php
$tz=timezone_open("America/New_York");
echo timezone_location_get($tz);
?>

運行實例

定義和用法

timezone_location_get() 返回給定時區的位置信息。

語法

timezone_location_get(object);
參數 描述
object 必需。規定由 timezone_open() 返回的 DateTimeZone 對象。

技術細節

返回值: 返回包含時區的位置信息的數組。
PHP 版本: 5.3+