Query Topics and Replies with option – visability : hidden
-
Hello,
For now my query looks like this.
global $wpdb; $myrows = $wpdb->get_results(" SELECT * FROM $wpdb->posts WHERE (post_type = 'reply' OR post_type = 'topic') AND post_status = 'publish' ORDER BY post_date DESC LIMIT 0, 15 ");
I made this at begining when just started developing project and now going to finish I want to make it more formal.
I think I’m gonna go with “query_posts”, but I’m still wondering how to hide posts that normal user is restricted to view. I’m talking about forum visability
Do I checkuser_can(moderate)
and then two ways to query my post?Any suggestions?
- You must be logged in to reply to this topic.