mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 01:27:36 +01:00
Ensure that apage and num cannot have negative values. Fixes #11786 props Denis-de-Bernardy.
git-svn-id: http://svn.automattic.com/wordpress/trunk@12637 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
197cdd2bbb
commit
d759368680
@ -308,8 +308,8 @@ switch( $_GET['action'] ) {
|
||||
|
||||
// List blogs
|
||||
default:
|
||||
$apage = isset( $_GET['apage'] ) ? intval( $_GET['apage'] ) : 1;
|
||||
$num = isset( $_GET['num'] ) ? intval( $_GET['num'] ) : 15;
|
||||
$apage = ( isset($_GET['apage'] ) && intval( $_GET['apage'] ) ) ? absint( $_GET['apage'] ) : 1;
|
||||
$num = ( isset($_GET['num'] ) && intval( $_GET['num'] ) ) ? absint( $_GET['num'] ) : 15;
|
||||
$s = wp_specialchars( trim( $_GET[ 's' ] ) );
|
||||
|
||||
$query = "SELECT * FROM {$wpdb->blogs} WHERE site_id = '{$wpdb->siteid}' ";
|
||||
|
Loading…
Reference in New Issue
Block a user