intval cat ID

git-svn-id: http://svn.automattic.com/wordpress/trunk@3824 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2006-06-01 07:42:46 +00:00
parent 4a47234d84
commit 2fce9d926e
1 changed files with 1 additions and 0 deletions

View File

@ -710,6 +710,7 @@ class WP_Query {
$cat_array = preg_split('/[,\s]+/', $q['cat']);
$in_cats = $out_cats = '';
foreach ( $cat_array as $cat ) {
$cat = intval($cat);
$in = strstr($cat, '-') ? false : true;
$cat = trim($cat, '-');
if ( $in )