Query all posts (even the ones without access)
-
Hello,
I would like to query all the posts even the ones the user does not have access to. Preferably i would like to show all the posts and have them go to a login screen when they click a post they do not have access to. Are there any args i can use to query all the posts and not just the ones the user has access to?
$args = array(
‘post_type’ => ‘custom’,
‘orderby’ => ‘title’,
‘order’ => ‘ASC’,
‘posts_per_page’ => 10,
‘paged’=>$paged
);Thanks
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
The topic ‘Query all posts (even the ones without access)’ is closed to new replies.