/*Reverse sticky header*/
  1. Home
  2. Knowledge Base
  3. Customizations
  4. PHP Functions
  5. How to Remove the Moderation Component’s Pop-up Being Rendered on MemberPress Pages

How to Remove the Moderation Component’s Pop-up Being Rendered on MemberPress Pages

The moderation component is currently being loaded on the MemberPress pages without a default option to exclude them. However, we have a snippet that you can use.  Please see the steps below to implement the workaround:

Note: Make sure to have a complete site backup before proceeding

    1. Go to Appearance – Theme Editor.

    2. Under Select theme to edit, choose (BuddyBoss Child/whatever theme is active), then click Select.

    3. Below Theme Files, select Theme Functions (functions.php).

    4. Append the code just before the closing PHP tag “?>”:

add_filter( "template_redirect", "remove_moderation_popup_on_memberpress_course" ); function remove_moderation_popup_on_memberpress_course(){ global $post; if($post instanceof \WP_Post && ( 'mpcs-course' === $post->post_type || 'mpcs-lesson' === $post->post_type || 'memberpressgroup' === $post->post_type ) ) { if( is_single() || is_post_type_archive( 'mpcs-course' ) ){ remove_action( 'wp_footer', 'bb_moderation_content_report_popup' ); } } }

    5. Click Update File to save the changes.

Note: Any modifications are considered as custom work already. Know more about our Support Policy here: https://www.buddyboss.com/support-policy/


Screenshots

Without Code:

With Code:

Was this article helpful?

Related Articles

Subscribe to Our Newsletter

Stay In Touch

Subscribe to our Newsletter, and we’ll send you the latest news from BuddyBoss

  • This field is hidden when viewing the form
  • This field is for validation purposes and should be left unchanged.

To speak to our Agency consultant, fill in the form found at our Contact Page.

"*" indicates required fields

Get Started

Enter your name and email address to get started with your project...

Name*
Profile photo of
Not recently active