Allow underscores in page names for meta box and column requests. see #8246

git-svn-id: https://develop.svn.wordpress.org/trunk@9759 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2008-11-18 18:38:20 +00:00
parent 27a6228430
commit 53ef19ae13
1 changed files with 2 additions and 2 deletions

View File

@ -819,7 +819,7 @@ case 'closed-postboxes' :
$hidden = isset( $_POST['hidden'] )? $_POST['hidden'] : '';
$hidden = explode( ',', $_POST['hidden'] );
$page = isset( $_POST['page'] )? $_POST['page'] : '';
if ( !preg_match( '/^[a-z-]+$/', $page ) ) {
if ( !preg_match( '/^[a-z-_]+$/', $page ) ) {
die(-1);
}
$current_user = wp_get_current_user();
@ -833,7 +833,7 @@ case 'hidden-columns' :
$hidden = isset( $_POST['hidden'] )? $_POST['hidden'] : '';
$hidden = explode( ',', $_POST['hidden'] );
$page = isset( $_POST['page'] )? $_POST['page'] : '';
if ( !preg_match( '/^[a-z-]+$/', $page ) ) {
if ( !preg_match( '/^[a-z-_]+$/', $page ) ) {
die(-1);
}
$current_user = wp_get_current_user();