diff options
| author | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2007-10-24 13:37:10 +0000 |
|---|---|---|
| committer | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2007-10-24 13:37:10 +0000 |
| commit | a1149064b86eac35bcead169cc34b0c2a3bb9c93 (patch) | |
| tree | 94b4c9668129c48029f0c285afa9ae6af966d3c9 /wp-admin/includes/post.php | |
| parent | d0b9489c96a012dfab70136e0fe7953a7d019c04 (diff) | |
| download | wordpress-mu-a1149064b86eac35bcead169cc34b0c2a3bb9c93.tar.gz wordpress-mu-a1149064b86eac35bcead169cc34b0c2a3bb9c93.tar.xz wordpress-mu-a1149064b86eac35bcead169cc34b0c2a3bb9c93.zip | |
WP Merge to revision 6287
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@1130 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-admin/includes/post.php')
| -rw-r--r-- | wp-admin/includes/post.php | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/wp-admin/includes/post.php b/wp-admin/includes/post.php index b88e3b0..3c9cc77 100644 --- a/wp-admin/includes/post.php +++ b/wp-admin/includes/post.php @@ -476,10 +476,12 @@ function _relocate_children( $old_ID, $new_ID ) { return $wpdb->query( "UPDATE $wpdb->posts SET post_parent = $new_ID WHERE post_parent = $old_ID" ); } -function wp_edit_posts_query( $q = '_GET' ) { +function wp_edit_posts_query( $q = false ) { global $wpdb; - $$q['m'] = (int) $$q['m']; - $$q['cat'] = (int) $$q['cat']; + if ( false === $q ) + $q = $_GET; + $q['m'] = (int) $q['m']; + $q['cat'] = (int) $q['cat']; $post_stati = array( // array( adj, noun ) 'draft' => array(__('Draft'), _c('Drafts|manage posts header')), 'future' => array(__('Scheduled'), __('Scheduled posts')), @@ -492,15 +494,15 @@ function wp_edit_posts_query( $q = '_GET' ) { $post_status_q = ''; $post_status_label = _c('Posts|manage posts header'); - if ( isset($$q['post_status']) && in_array( $$q['post_status'], array_keys($post_stati) ) ) { - $post_status_label = $post_stati[$$q['post_status']][1]; - $post_status_q = '&post_status=' . $$q['post_status']; + if ( isset($q['post_status']) && in_array( $q['post_status'], array_keys($post_stati) ) ) { + $post_status_label = $post_stati[$q['post_status']][1]; + $post_status_q = '&post_status=' . $q['post_status']; } - if ( 'pending' === $$q['post_status'] ) { + if ( 'pending' === $q['post_status'] ) { $order = 'ASC'; $orderby = 'modified'; - } elseif ( 'draft' === $$q['post_status'] ) { + } elseif ( 'draft' === $q['post_status'] ) { $order = 'DESC'; $orderby = 'modified'; } else { |
