Exclude deprecated timezones. see #3962
git-svn-id: https://develop.svn.wordpress.org/trunk@10755 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
f4c5df18b4
commit
e370b4740f
|
@ -3109,10 +3109,14 @@ function wp_timezone_choice($selectedzone) {
|
||||||
$structure = '';
|
$structure = '';
|
||||||
$pad = ' ';
|
$pad = ' ';
|
||||||
|
|
||||||
|
$continents = array('Africa', 'America', 'Antarctica', 'Arctic', 'Asia', 'Atlantic', 'Australia', 'Europe', 'Indian', 'Pacific', 'Etc');
|
||||||
|
|
||||||
if ( empty($selectedzone) )
|
if ( empty($selectedzone) )
|
||||||
$structure .= '<option selected="selected" value="">' . __('Select a city') . "</option>\n";
|
$structure .= '<option selected="selected" value="">' . __('Select a city') . "</option>\n";
|
||||||
foreach ( $zonen as $zone ) {
|
foreach ( $zonen as $zone ) {
|
||||||
extract($zone);
|
extract($zone);
|
||||||
|
if ( ! in_array($continent, $continents) )
|
||||||
|
continue;
|
||||||
if ( empty($selectcontinent) && !empty($city) ) {
|
if ( empty($selectcontinent) && !empty($city) ) {
|
||||||
$selectcontinent = $continent;
|
$selectcontinent = $continent;
|
||||||
$structure .= '<optgroup label="'.$continent.'">' . "\n"; // continent
|
$structure .= '<optgroup label="'.$continent.'">' . "\n"; // continent
|
||||||
|
|
Loading…
Reference in New Issue