Exclamation mark is a valid and safe character in a URI. props hakre. fixes #8904

git-svn-id: http://svn.automattic.com/wordpress/trunk@11147 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
markjaquith 2009-04-30 23:52:32 +00:00
parent cbf39b4bf0
commit 42ae25cb48
1 changed files with 1 additions and 1 deletions

View File

@ -876,7 +876,7 @@ if ( !function_exists('wp_sanitize_redirect') ) :
* @return string redirect-sanitized URL
**/
function wp_sanitize_redirect($location) {
$location = preg_replace('|[^a-z0-9-~+_.?#=&;,/:%]|i', '', $location);
$location = preg_replace('|[^a-z0-9-~+_.?#=&;,/:%!]|i', '', $location);
$location = wp_kses_no_null($location);
// remove %0d and %0a from location