_wp_timezone_choice_usort_callback [ WordPress Function ]
_wp_timezone_choice_usort_callback ( $a, $b )
| Parameters: |
|
| Returns: |
|
| Defined at: |
|
Benzer Fonksiyonlar: wp_timezone_choice, wp_timezone_override_offset, _wp_object_count_sort_cb, wp_timezone_supported, _wp_dashboard_control_callback
{@internal Missing Short Description}}
Source
<?php
function _wp_timezone_choice_usort_callback( $a, $b ) {
// Don't use translated versions of Etc
if ( 'Etc' === $a['continent'] && 'Etc' === $b['continent'] ) {
// Make the order of these more like the old dropdown
if ( 'GMT+' === substr( $a['city'], 0, 4 ) && 'GMT+' === substr( $b['city'], 0, 4 ) ) {
return -1 * ( strnatcasecmp( $a['city'], $b['city'] ) );
}
if ( 'UTC' === $a['city'] ) {
if ( 'GMT+' === substr( $b['city'], 0, 4 ) ) {
return 1;
}
return -1;
}
if ( 'UTC' === $b['city'] ) {
if ( 'GMT+' === substr( $a['city'], 0, 4 ) ) {
return -1;
}
return 1;
}
return strnatcasecmp( $a['city'], $b['city'] );
}
if ( $a['t_continent'] == $b['t_continent'] ) {
if ( $a['t_city'] == $b['t_city'] ) {
return strnatcasecmp( $a['t_subcity'], $b['t_subcity'] );
}
return strnatcasecmp( $a['t_city'], $b['t_city'] );
} else {
// Force Etc to the bottom of the list
if ( 'Etc' === $a['continent'] ) {
return 1;
}
if ( 'Etc' === $b['continent'] ) {
return -1;
}
return strnatcasecmp( $a['t_continent'], $b['t_continent'] );
}
}
?>
Examples [ wp-snippets.com ]
Google Arama Sonuçlarý
- Docs for page functions.core.php
_wp_timezone_choice_usort_callback (line 864). void _wp_timezone_choice_usort_callback ( $a, $b). $a; $b. Documentation generated on Sat, 19 May 2012 ...
phpdoc.ftwr.co.uk - wp_timezone_choice (WordPress Function) - WPSeek.com
Similar Functions: wp_timezone_supported, _wp_timezone_choice_usort_callback, wp_timezone_override_offset, wp_tiny_mce, wp_comment_trashnotice ...
wpseek.com - Database Error
... 'continents-cities' ) : '' ) ); } usort( $zonen, ' _wp_timezone_choice_usort_callback' ); $structure = array(); if ( empty( $ selected_zone ) ) { $structure[] = ' ' .
www.rit.edu - #19552 (Split functions.php) – WordPress Trac
... set_site_transient() is_main_site() global_terms_enabled() wp_timezone_override_offset() _wp_timezone_choice_usort_callback() wp_timezone_choice() ...
core.trac.wordpress.org