Eliminate double urlencode()ing in add_query_arg(). Move &-to-& conversion to wp_nonce_url(). fixes #4884
git-svn-id: https://develop.svn.wordpress.org/trunk@6008 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
71820cb422
commit
d0d887d09d
@ -606,8 +606,6 @@ function add_query_arg() {
|
||||
$uri = @func_get_arg(2);
|
||||
}
|
||||
|
||||
$uri = str_replace('&', '&', $uri);
|
||||
|
||||
if ( $frag = strstr($uri, '#') )
|
||||
$uri = substr($uri, 0, -strlen($frag));
|
||||
else
|
||||
@ -638,7 +636,6 @@ function add_query_arg() {
|
||||
}
|
||||
|
||||
wp_parse_str($query, $qs);
|
||||
$qs = urlencode_deep($qs);
|
||||
if ( is_array(func_get_arg(0)) ) {
|
||||
$kayvees = func_get_arg(0);
|
||||
$qs = array_merge($qs, $kayvees);
|
||||
@ -853,6 +850,7 @@ function is_blog_installed() {
|
||||
}
|
||||
|
||||
function wp_nonce_url($actionurl, $action = -1) {
|
||||
$actionurl = str_replace('&', '&', $actionurl);
|
||||
return wp_specialchars(add_query_arg('_wpnonce', wp_create_nonce($action), $actionurl));
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user