@@ -6709,7 +6709,7 @@ function wp_timezone_choice( $selected_zone, $locale = null ) {
67096709 if ( in_array ( $ selected_zone , $ tz_identifiers , true ) === false
67106710 && in_array ( $ selected_zone , timezone_identifiers_list ( DateTimeZone::ALL_WITH_BC ), true )
67116711 ) {
6712- $ structure [] = '<option selected="selected" value=" ' . esc_attr ( $ selected_zone ) . '"> ' . esc_html ( $ selected_zone ) . '</option> ' ;
6712+ $ structure [] = '<option selected="selected" value=" ' . esc_attr ( $ selected_zone ) . '" dir="auto" > ' . esc_html ( $ selected_zone ) . '</option> ' ;
67136713 }
67146714
67156715 foreach ( $ zonen as $ key => $ zone ) {
@@ -6725,7 +6725,7 @@ function wp_timezone_choice( $selected_zone, $locale = null ) {
67256725 // Continent optgroup.
67266726 if ( ! isset ( $ zonen [ $ key - 1 ] ) || $ zonen [ $ key - 1 ]['continent ' ] !== $ zone ['continent ' ] ) {
67276727 $ label = $ zone ['t_continent ' ];
6728- $ structure [] = '<optgroup label=" ' . esc_attr ( $ label ) . '"> ' ;
6728+ $ structure [] = '<optgroup label=" ' . esc_attr ( $ label ) . '" dir="auto" > ' ;
67296729 }
67306730
67316731 // Add the city to the value.
@@ -6745,7 +6745,7 @@ function wp_timezone_choice( $selected_zone, $locale = null ) {
67456745 if ( $ value === $ selected_zone ) {
67466746 $ selected = 'selected="selected" ' ;
67476747 }
6748- $ structure [] = '<option ' . $ selected . 'value=" ' . esc_attr ( $ value ) . '"> ' . esc_html ( $ display ) . '</option> ' ;
6748+ $ structure [] = '<option ' . $ selected . 'value=" ' . esc_attr ( $ value ) . '" dir="auto" > ' . esc_html ( $ display ) . '</option> ' ;
67496749
67506750 // Close continent optgroup.
67516751 if ( ! empty ( $ zone ['city ' ] ) && ( ! isset ( $ zonen [ $ key + 1 ] ) || ( isset ( $ zonen [ $ key + 1 ] ) && $ zonen [ $ key + 1 ]['continent ' ] !== $ zone ['continent ' ] ) ) ) {
@@ -6754,16 +6754,16 @@ function wp_timezone_choice( $selected_zone, $locale = null ) {
67546754 }
67556755
67566756 // Do UTC.
6757- $ structure [] = '<optgroup label=" ' . esc_attr__ ( 'UTC ' ) . '"> ' ;
6757+ $ structure [] = '<optgroup label=" ' . esc_attr__ ( 'UTC ' ) . '" dir="auto" > ' ;
67586758 $ selected = '' ;
67596759 if ( 'UTC ' === $ selected_zone ) {
67606760 $ selected = 'selected="selected" ' ;
67616761 }
6762- $ structure [] = '<option ' . $ selected . 'value=" ' . esc_attr ( 'UTC ' ) . '"> ' . __ ( 'UTC ' ) . '</option> ' ;
6762+ $ structure [] = '<option ' . $ selected . 'value=" ' . esc_attr ( 'UTC ' ) . '" dir="auto" > ' . __ ( 'UTC ' ) . '</option> ' ;
67636763 $ structure [] = '</optgroup> ' ;
67646764
67656765 // Do manual UTC offsets.
6766- $ structure [] = '<optgroup label=" ' . esc_attr__ ( 'Manual Offsets ' ) . '"> ' ;
6766+ $ structure [] = '<optgroup label=" ' . esc_attr__ ( 'Manual Offsets ' ) . '" dir="auto" > ' ;
67676767 $ offset_range = array (
67686768 -12 ,
67696769 -11.5 ,
@@ -6836,8 +6836,7 @@ function wp_timezone_choice( $selected_zone, $locale = null ) {
68366836 if ( $ offset_value === $ selected_zone ) {
68376837 $ selected = 'selected="selected" ' ;
68386838 }
6839- $ structure [] = '<option ' . $ selected . 'value=" ' . esc_attr ( $ offset_value ) . '"> ' . esc_html ( $ offset_name ) . '</option> ' ;
6840-
6839+ $ structure [] = '<option ' . $ selected . 'value=" ' . esc_attr ( $ offset_value ) . '" dir="auto"> ' . esc_html ( $ offset_name ) . '</option> ' ;
68416840 }
68426841 $ structure [] = '</optgroup> ' ;
68436842
0 commit comments