From 8b1e622739ff6d72859f0792672a0a9d075856c7 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Fri, 30 Jun 2006 00:43:23 +0000 Subject: [PATCH] Allow % so entities such as slashes don't break. git-svn-id: https://develop.svn.wordpress.org/trunk@3939 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/pluggable.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/wp-includes/pluggable.php b/wp-includes/pluggable.php index 084f24a95b..103b5445c8 100644 --- a/wp-includes/pluggable.php +++ b/wp-includes/pluggable.php @@ -260,7 +260,10 @@ if ( !function_exists('wp_redirect') ) : function wp_redirect($location) { global $is_IIS; - $location = preg_replace('|[^a-z0-9-~+_.?#=&;,/:]|i', '', $location); + $location = preg_replace('|[^a-z0-9-~+_.?#=&;,/:%]|i', '', $location); + + $strip = array('%0d', '%0a'); + $location = str_replace($strip, '', $location); if ($is_IIS) header("Refresh: 0;url=$location");