Changeset 14786 for trunk/wp-content/themes/twentyten/header.php
- Timestamp:
- 05/21/2010 06:56:27 PM (16 years ago)
- File:
-
- 1 edited
-
trunk/wp-content/themes/twentyten/header.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-content/themes/twentyten/header.php
r14708 r14786 14 14 <meta charset="<?php bloginfo( 'charset' ); ?>" /> 15 15 <title> 16 <?php 17 if ( is_single() ) { 16 <?php // Returns the title based on what is being viewed 17 if ( is_single() ) { // single posts 18 18 single_post_title(); echo ' | '; bloginfo( 'name' ); 19 // The home page or, if using a static front page, the blog posts page. 19 20 } elseif ( is_home() || is_front_page() ) { 20 bloginfo( 'name' ); 21 if( get_bloginfo( 'description' ) ) 22 echo ' | ' ; bloginfo( 'description' ); 21 bloginfo( 'name' ); 22 if( get_bloginfo( 'description' ) ) 23 echo ' | ' ; bloginfo( 'description' ); 23 24 twentyten_the_page_number(); 24 } elseif ( is_page() ) { 25 } elseif ( is_page() ) { // WordPress Pages 25 26 single_post_title( '' ); echo ' | '; bloginfo( 'name' ); 26 } elseif ( is_search() ) { 27 } elseif ( is_search() ) { // Search results 27 28 printf( __( 'Search results for %s', 'twentyten' ), '"'.get_search_query().'"' ); twentyten_the_page_number(); echo ' | '; bloginfo( 'name' ); 28 } elseif ( is_404() ) { 29 } elseif ( is_404() ) { // 404 (Not Found) 29 30 _e( 'Not Found', 'twentyten' ); echo ' | '; bloginfo( 'name' ); 30 } else { 31 } else { // Otherwise: 31 32 wp_title( '' ); echo ' | '; bloginfo( 'name' ); twentyten_the_page_number(); 32 33 } … … 35 36 <link rel="profile" href="http://gmpg.org/xfn/11" /> 36 37 <link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_url' ); ?>" /> 37 <?php if ( is_singular() && get_option( 'thread_comments' ) ) wp_enqueue_script( 'comment-reply' ); ?>38 38 <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" /> 39 <?php wp_head(); ?> 39 <?php 40 /* We add some JavaScript to pages with the comment form 41 * to support sites with threaded comments (when in use). 42 */ 43 if ( is_singular() && get_option( 'thread_comments' ) ) 44 wp_enqueue_script( 'comment-reply' ); 45 46 /* Always have wp_head() just before the closing </head> 47 * tag of your theme, or you will break many plugins, which 48 * generally use this hook to add elements to <head> such 49 * as styles, scripts, and meta tags. 50 */ 51 52 wp_head(); 53 ?> 40 54 </head> 41 55 … … 67 81 68 82 <div id="access" role="navigation"> 83 <?php /* Allow screen readers / text browsers to skip the navigation menu and get right to the good stuff */ ?> 69 84 <div class="skip-link screen-reader-text"><a href="#content" title="<?php esc_attr_e( 'Skip to content', 'twentyten' ); ?>"><?php _e( 'Skip to content', 'twentyten' ); ?></a></div> 85 <?php /* Our navigation menu. If one isn't filled out, wp_nav_menu falls back to wp_page_menu. The menu assiged to the primary position is the one used. If none is assigned, the menu with the lowest ID is used. */ ?> 70 86 <?php wp_nav_menu( array( 'sort_column' => 'menu_order', 'container_class' => 'menu-header', 'theme_location' => 'primary' ) ); ?> 71 87 </div><!-- #access -->
Note: See TracChangeset
for help on using the changeset viewer.