WordPress.org

Make WordPress Core

Ticket #9103: 9103.diff

File 9103.diff, 733 bytes (added by DD32, 9 years ago)
  • wp-includes/general-template.php

     
    385385        $year = get_query_var('year');
    386386        $monthnum = get_query_var('monthnum');
    387387        $day = get_query_var('day');
     388        $search = get_query_var('s');
    388389        $title = '';
    389390
    390391        $t_sep = '%WP_TITILE_SEP%'; // Temporary separator, for accurate flipping, if necessary
     
    457458                $title = "$tax$t_sep$term";
    458459        }
    459460
     461        //If it's a search
     462        if ( is_search() ) {
     463                $title = sprintf(__('Search Results %s %s'), $t_sep, wp_specialchars($search));
     464        }
     465
    460466        if ( is_404() ) {
    461467                $title = __('Page not found');
    462468        }