Make WordPress Core

Ticket #51307: 51307.2.patch

File 51307.2.patch, 1.4 KB (added by mukesh27, 4 years ago)

Initial patch.

  • src/wp-includes/general-template.php

     
    11521152                /* translators: %s: Search query. */
    11531153                $title['title'] = sprintf( __( 'Search Results for “%s”' ), get_search_query() );
    11541154
    1155                 // If on the front page, use the site title.
    1156         } elseif ( is_front_page() ) {
     1155                // If we're on the front page or blog page, use the site title.
     1156        } elseif ( is_front_page() || is_home() ) {
    11571157                $title['title'] = get_bloginfo( 'name', 'display' );
    11581158
    11591159                // If on a post type archive, use the post type archive title.
     
    11641164        } elseif ( is_tax() ) {
    11651165                $title['title'] = single_term_title( '', false );
    11661166
    1167                 /*
    1168                 * If we're on the blog page that is not the homepage
    1169                 * or a single post of any post type, use the post title.
    1170                 */
     1167                // If on a single post of any post type, use the post title.
    11711168        } elseif ( is_home() || is_singular() ) {
    11721169                $title['title'] = single_post_title( '', false );
    11731170
     
    11981195        }
    11991196
    12001197        // Append the description or site title to give context.
    1201         if ( is_front_page() ) {
     1198        if ( is_front_page() || is_home() ) {
    12021199                $title['tagline'] = get_bloginfo( 'description', 'display' );
    12031200        } else {
    12041201                $title['site'] = get_bloginfo( 'name', 'display' );