Have get_search_query() escape by default, like it's echoing counterpart the_search_query(). see #12780

git-svn-id: https://develop.svn.wordpress.org/trunk@13978 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin
2010-04-03 23:38:38 +00:00
parent b1aa2af855
commit ebd39b1233
5 changed files with 21 additions and 12 deletions

View File

@@ -167,7 +167,7 @@ else
<?php screen_icon(); ?>
<h2><?php echo esc_html( $title ); ?> <a href="<?php echo $post_new_file ?>" class="button add-new-h2"><?php echo esc_html_x('Add New', 'post'); ?></a> <?php
if ( isset($_GET['s']) && $_GET['s'] )
printf( '<span class="subtitle">' . __('Search results for &#8220;%s&#8221;') . '</span>', esc_html( get_search_query() ) ); ?>
printf( '<span class="subtitle">' . __('Search results for &#8220;%s&#8221;') . '</span>', get_search_query() ); ?>
</h2>
<?php