Add search string to H2s, fixes #8373

git-svn-id: http://svn.automattic.com/wordpress/trunk@10034 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
azaozz 2008-12-04 09:20:52 +00:00
parent b9b1b76b0b
commit e53337ede8
9 changed files with 18 additions and 9 deletions

View File

@ -131,7 +131,8 @@ $messages[5] = __('Category not updated.');
<div class="wrap nosubsub">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php $h2_search = isset($_GET['s']) && $_GET['s'] ? ' ' . sprintf(__('matching &#8220;%s&#8221;'), wp_specialchars( stripslashes($_GET['s']) ) ) : ''; ?>
<h2><?php echo wp_specialchars( $title ) . $h2_search; ?></h2>
<?php
if ( isset($_GET['message']) && ( $msg = (int) $_GET['message'] ) ) : ?>

View File

@ -86,7 +86,8 @@ $search = attribute_escape( $search_dirty ); ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php $h2_search = isset($_GET['s']) && $_GET['s'] ? ' ' . sprintf(__('matching &#8220;%s&#8221;'), wp_specialchars( stripslashes($_GET['s']) ) ) : ''; ?>
<h2><?php echo wp_specialchars( $title ) . $h2_search; ?></h2>
<?php
if ( isset( $_GET['approved'] ) || isset( $_GET['deleted'] ) || isset( $_GET['spam'] ) ) {

View File

@ -61,7 +61,8 @@ $messages[6] = __('Categories deleted.'); ?>
<div class="wrap nosubsub">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php $h2_search = isset($_GET['s']) && $_GET['s'] ? ' ' . sprintf(__('matching &#8220;%s&#8221;'), wp_specialchars( stripslashes($_GET['s']) ) ) : ''; ?>
<h2><?php echo wp_specialchars( $title ) . $h2_search; ?></h2>
<?php if ( isset($_GET['message']) && ( $msg = (int) $_GET['message'] ) ) : ?>
<div id="message" class="updated fade"><p><?php echo $messages[$msg]; ?></p></div>

View File

@ -104,7 +104,8 @@ require_once('admin-header.php'); ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php $h2_search = isset($_GET['s']) && $_GET['s'] ? ' ' . sprintf(__('matching &#8220;%s&#8221;'), wp_specialchars( get_search_query() ) ) : ''; ?>
<h2><?php echo wp_specialchars( $title ) . $h2_search; ?></h2>
<?php if ( isset($_GET['locked']) || isset($_GET['skipped']) || isset($_GET['updated']) || isset($_GET['deleted']) ) { ?>
<div id="message" class="updated fade"><p>

View File

@ -130,7 +130,8 @@ $messages[6] = __('Tags deleted.'); ?>
<div class="wrap nosubsub">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php $h2_search = isset($_GET['s']) && $_GET['s'] ? ' ' . sprintf(__('matching &#8220;%s&#8221;'), wp_specialchars( stripslashes($_GET['s']) ) ) : ''; ?>
<h2><?php echo wp_specialchars( $title ) . $h2_search; ?></h2>
<?php if ( isset($_GET['message']) && ( $msg = (int) $_GET['message'] ) ) : ?>
<div id="message" class="updated fade"><p><?php echo $messages[$msg]; ?></p></div>

View File

@ -96,7 +96,8 @@ else
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php $h2_search = isset($_GET['s']) && $_GET['s'] ? ' ' . sprintf(__('matching &#8220;%s&#8221;'), wp_specialchars( get_search_query() ) ) : ''; ?>
<h2><?php echo wp_specialchars( $title ) . $h2_search; ?></h2>
<?php
if ( isset($_GET['posted']) && $_GET['posted'] ) : $_GET['posted'] = (int) $_GET['posted']; ?>

View File

@ -71,7 +71,8 @@ switch ($order_by) {
<div class="wrap nosubsub">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php $h2_search = isset($_GET['s']) && $_GET['s'] ? ' ' . sprintf(__('matching &#8220;%s&#8221;'), wp_specialchars( stripslashes($_GET['s']) ) ) : ''; ?>
<h2><?php echo wp_specialchars( $title ) . $h2_search; ?></h2>
<?php
if ( isset($_GET['deleted']) ) {

View File

@ -164,7 +164,8 @@ if ( isset($_GET['message']) && (int) $_GET['message'] ) {
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php $h2_search = isset($_GET['s']) && $_GET['s'] ? ' ' . sprintf(__('matching &#8220;%s&#8221;'), wp_specialchars( get_search_query() ) ) : ''; ?>
<h2><?php echo wp_specialchars( $title ) . $h2_search; ?></h2>
<?php
if ( isset($message) ) { ?>

View File

@ -239,7 +239,8 @@ if ( ! empty($messages) ) {
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php $h2_search = isset($_GET['s']) && $_GET['s'] ? ' ' . sprintf(__('matching &#8220;%s&#8221;'), wp_specialchars( get_search_query() ) ) : ''; ?>
<h2><?php echo wp_specialchars( $title ) . $h2_search; ?></h2>
<div class="filter">
<form id="list-filter" action="" method="get">