Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- // Query defaults
- $topics_query = array(
- 'author' => 0,
- 'show_stickies' => false,
- 'parent_forum' => 'any',
- 'posts_per_page' => 5,
- 'order' => 'DESC',
- );
- bbp_set_query_name( 'bbp_is_topic_archive' );
- // Before topics index
- do_action( 'bbp_template_before_topics_index' );
- // Load the topic index
- if ( bbp_has_topics( $topics_query ) ) {
- bbp_get_template_part( 'bbpress/pagination', 'topics' );
- bbp_get_template_part( 'bbpress/loop', 'topics' );
- bbp_get_template_part( 'bbpress/pagination', 'topics' );
- // No topics
- } else {
- bbp_get_template_part( 'bbpress/feedback', 'no-topics' );
- }
- // After topics index
- do_action( 'bbp_template_after_topics_index' );
- bbp_reset_query_name();
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement