Ticket #21233: 21233.2.diff
File 21233.2.diff, 1.8 KB (added by , 13 years ago) |
---|
-
wp-content/themes/twentytwelve/header.php
13 13 <head> 14 14 <meta charset="<?php bloginfo( 'charset' ); ?>" /> 15 15 <meta name="viewport" content="width=device-width, initial-scale=1.0" /> 16 <title><?php wp_title( '|', true, 'right' ); ?>< ?php echo bloginfo( 'name' ); ?></title>16 <title><?php wp_title( '|', true, 'right' ); ?></title> 17 17 <link rel="profile" href="http://gmpg.org/xfn/11" /> 18 18 <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" /> 19 19 <!--[if lt IE 9]> -
wp-content/themes/twentytwelve/functions.php
131 131 add_action( 'wp_enqueue_scripts', 'twentytwelve_scripts_styles' ); 132 132 133 133 /** 134 * Returns the <title> tag based on what is being viewed. 135 * 136 * @since Twenty Twelve 1.0 137 */ 138 function twentytwelve_wp_title( $title, $sep ) { 139 global $paged, $page; 140 141 // Add the blog name. 142 $title .= get_bloginfo( 'name' ); 143 144 // Add the blog description for the home/front page. 145 $site_description = get_bloginfo( 'description', 'display' ); 146 if ( $site_description && ( is_home() || is_front_page() ) ) 147 $title = "$title $sep $site_description"; 148 149 // Add a page number if necessary: 150 if ( $paged >= 2 || $page >= 2 ) 151 $title = "$title $sep " . sprintf( __( 'Page %s', 'twentytwelve' ), max( $paged, $page ) ); 152 153 return $title; 154 } 155 add_filter( 'wp_title', 'twentytwelve_wp_title', 10, 2 ); 156 157 /** 134 158 * Get our wp_nav_menu() fallback, wp_page_menu(), to show a home link. 135 159 * 136 160 * @since Twenty Twelve 1.0