/** * Return the contents of the output buffer and flush its contents. * * @since bbPress( r3079) * * @uses BBP_Shortcodes::unset_globals() Cleans up global values * @return string Contents of output buffer. */ private function end() { // Put output into usable variable $output = ob_get_contents(); // Unset globals $this->unset_globals(); // Flush the output buffer ob_end_clean(); // Reset the query name bbp_reset_query_name(); // Add 'bbp_replace_the_content' filter back (@see $this::start()) add_filter('the_content', 'bbp_replace_the_content'); return $output; }
<?php bbp_get_template_part('pagination', 'topics'); ?> <?php bbp_get_template_part('loop', 'topics'); ?> <?php bbp_get_template_part('pagination', 'topics'); ?> <?php } else { ?> <?php bbp_get_template_part('feedback', 'no-topics'); ?> <?php } ?> <?php bbp_reset_query_name(); ?> </div>
/** * Return the contents of the output buffer and flush its contents. * * @since bbPress( r3079) * * @uses BBP_Shortcodes::unset_globals() Cleans up global values * @return string Contents of output buffer. */ private function end() { // Unset globals $this->unset_globals(); // Reset the query name bbp_reset_query_name(); // Return and flush the output buffer return ob_get_clean(); }