Changeset 4218
- Timestamp:
- 09/24/2006 08:16:13 PM (20 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
-
wp-admin/admin-header.php (modified) (1 diff)
-
wp-includes/general-template.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/admin-header.php
r4217 r4218 14 14 ?> 15 15 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 16 <html xmlns="http://www.w3.org/1999/xhtml" dir="<?php bloginfo('text_direction'); ?>" lang="<?php bloginfo('language'); ?>" xml:lang="<?php bloginfo('language'); ?>">16 <html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>> 17 17 <head> 18 18 <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php echo get_option('blog_charset'); ?>" /> -
trunk/wp-includes/general-template.php
r4217 r4218 130 130 case 'language': 131 131 $output = get_locale(); 132 if ( empty($output) )133 $output = 'en-US';134 132 $output = str_replace('_', '-', $output); 135 133 break; … … 137 135 global $wp_locale; 138 136 $output = $wp_locale->text_direction; 139 if ( empty($output) )140 $output = 'ltr';141 137 break; 142 138 case 'name': … … 871 867 } 872 868 869 function language_attributes() { 870 $output = ''; 871 if ( $dir = get_bloginfo('text_direction') ) 872 $output = "dir=\"$dir\""; 873 if ( $lang = get_bloginfo('language') ) { 874 if ( $dir ) $output .= ' '; 875 $output .= "lang=\"$lang\" xml:lang=\"$lang\""; 876 } 877 878 echo $output; 879 } 873 880 ?>
Note: See TracChangeset
for help on using the changeset viewer.