urldecode() search strings that come in from /search/foo. props SergeyBiryukov. fixes #13961
git-svn-id: https://develop.svn.wordpress.org/trunk@21187 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
e1b03b4fd4
commit
0b294b9481
@ -2177,6 +2177,8 @@ class WP_Query {
|
||||
if ( !empty($q['s']) ) {
|
||||
// added slashes screw with quote grouping when done early, so done later
|
||||
$q['s'] = stripslashes($q['s']);
|
||||
if ( empty( $_GET['s'] ) && is_main_query() )
|
||||
$q['s'] = urldecode($q['s']);
|
||||
if ( !empty($q['sentence']) ) {
|
||||
$q['search_terms'] = array($q['s']);
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user