Display posts with ‘future’ status
-
Hi there,
I (probably unusually) want to display single posts with a status of future, but only if they’re in a specific category.
So far as I can see, get_posts just scrubs the posts array of anything unpublished if the user isn’t logged on (which they won’t be). See wp-includes/query.php:2288.
I thought about doing something really hacky with is_user_logged_in, along the lines of:
if(is_single() && is_in_my_category()) { return true; } else { [normal code from pluggables] }
but that creates its own problems and is generally pretty horrid anyway.
Can anyone think of a nice way to do it?
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Display posts with ‘future’ status’ is closed to new replies.