Hàm timezone_name_from_abbr () trong PHP
Thí dụ
Trả lại tên múi giờ từ viết tắt:
<?php
echo timezone_name_from_abbr("EST") . "<br>";
echo timezone_name_from_abbr("",7200,0);
?>
Định nghĩa và Cách sử dụng
Timezone_name_from_abbr () trả về tên múi giờ từ viết tắt.
Cú pháp
timezone_name_from_abbr(abbr, gmtoffset, isdst)
Giá trị tham số
Parameter | Description |
---|---|
abbr | Required. Specifies the timezone abbreviation |
gmtoffset | Optional. Specifies the offset from GMT in seconds. Default is -1, which means that first found timezone corresponding to abbr is returned. Otherwise exact offset is searched. If not found, the first timezone with any offset is returned |
isdst |
Optional. Specifies daylight saving time indicator.
|
Chi tiết kỹ thuật
Giá trị trả lại: | Trả về tên múi giờ khi thành công. FALSE khi thất bại |
---|---|
Phiên bản PHP: | 5.1.3+ |
❮ Tham chiếu ngày / giờ PHP