Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- Only redirect away from single topic and single reply pages.
- Add this code to a custom plugin.
- */
- function wp_maybe_disable_pmprobbp_check_forum() {
- global $post;
- if(function_exists('bbp_is_topic') && !bbp_is_topic($post->ID) && !bbp_is_reply($post->ID)) {
- remove_action( 'template_redirect', 'pmprobbp_check_forum' );
- remove_filter( 'pmpro_search_filter_post_types', 'pmprobb_pmpro_search_filter_post_types' );
- remove_filter( 'pre_get_posts', 'pmprobb_pre_get_posts' );
- }
- }
- add_action('template_redirect', 'wp_maybe_disable_pmprobbp_check_forum', 1);
Add Comment
Please, Sign In to add comment