Do only the minimum sanitization on the URL redirect. fixes #2994
git-svn-id: https://develop.svn.wordpress.org/trunk@4268 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
24cd5df33c
commit
384b956cc1
@ -44,11 +44,15 @@ case 'update':
|
||||
$f = fopen($real_file, 'w+');
|
||||
fwrite($f, $newcontent);
|
||||
fclose($f);
|
||||
wp_redirect("theme-editor.php?file=$file&theme=$theme&a=te");
|
||||
$location = "theme-editor.php?file=$file&theme=$theme&a=te";
|
||||
} else {
|
||||
wp_redirect("theme-editor.php?file=$file&theme=$theme");
|
||||
$location = "theme-editor.php?file=$file&theme=$theme";
|
||||
}
|
||||
|
||||
$location = wp_kses_no_null($location);
|
||||
$strip = array('%0d', '%0a');
|
||||
$location = str_replace($strip, '', $location);
|
||||
header("Location: $location");
|
||||
exit();
|
||||
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user