(PHP 5 >= 5.2.0, PHP 7)
DateTimeZone::listIdentifiers -- timezone_identifiers_list — ����һ������������ʱ����ʾ�����������顣
���������
$what = DateTimeZone::ALL
[, string $country = NULL
]] ) : array���̻����
whatDateTimeZone ���еij���֮һ��
country��������ĸ��ɣ�ISO 3166-1 ���ݵĹ��Ҵ��롣
Note: ֻ�е�
what������ΪDateTimeZone::PER_COUNTRYʱ,��ѡ��Żᱻʹ�á�
�ɹ����������飬ʧ����FALSE.
| �汾 | ˵�� |
|---|---|
| 5.3.0 |
��ӿ�ѡ�� what ��
country ������
|
Example #1 timezone_identifiers_list() ���������
<?php
$timezone_identifiers = DateTimeZone::listIdentifiers();
for ($i=0; $i < 5; $i++) {
echo "$timezone_identifiers[$i]\n";
}
?>
�������̵���������ڣ�
Africa/Abidjan Africa/Accra Africa/Addis_Ababa Africa/Algiers Africa/Asmara