Help with excluding hidden, spam, and closed topics from the front page.
Hey everyone, I’m having a bit of trouble with my query. I’m display forum posts on the home page of my wordpress site so they kind of look a bit like a blog post. What I’m having a hard time figuring out is, how can I exclude spam, hidden, and closed topics from veiw on that page.
Basically, I only want to show open topics on the home page, the part o the code in question is…
$bbp_loop_args = array(
'post_type' => bbp_get_topic_post_type(),
'orderby' => 'date',
'order' => 'DESC',
'post__not_in' => bbp_get_super_stickies(),
'posts_per_page' => 10,
if ( bbp_has_topics( $bbp_loop_args ) ) :
if ( bbp_topics() ) : bbp_the_topic();
$more = 0;
get_template_part( 'content', get_post_format() );
echo '<ol class="other-recent-posts">';
I’m able to exclude super-stickies easily enough, but excluding hidden, spam, and closed topics is eluding me.
Anyone out there have any Ideas?
- You must be logged in to reply to this topic.