mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-03-31 10:44:26 +00:00
Static pages. Take 1.
git-svn-id: https://develop.svn.wordpress.org/trunk@1527 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -454,11 +454,16 @@ class WP_Query {
|
||||
|
||||
$distinct = 'DISTINCT';
|
||||
}
|
||||
$where .= ' AND (post_status = "publish"';
|
||||
|
||||
if ('' != $q['static']) {
|
||||
$where .= ' AND (post_status = "static"';
|
||||
} else {
|
||||
$where .= ' AND (post_status = "publish"';
|
||||
}
|
||||
|
||||
// Get private posts
|
||||
if (isset($user_ID) && ('' != intval($user_ID)))
|
||||
$where .= " OR post_author = $user_ID AND post_status != 'draft')";
|
||||
$where .= " OR post_author = $user_ID AND post_status != 'draft' AND post_status != 'static')";
|
||||
else
|
||||
$where .= ')';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user