[Resolved] Buddypress groups home page conflict

Home Forums Support [Resolved] Buddypress groups home page conflict

Home Forums Support Buddypress groups home page conflict

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1379790
    Jeffrey

    I am having a conflict with the home page header element showing up on the buddypress groups home page. Tried a number of options including excluding it from the pages to display on. No luck.

    Any idea on how to stop the “font page” header element from showing up on the buddypress groups home page?

    #1379869
    Leo
    Staff
    Customer Support

    Hi there,

    I think we would need a solution like this:
    https://generatepress.com/forums/topic/bbpress-forum-root-not-taking-into-account-elements/#post-667950

    Try replacing 10 with the actual ID of the header element and replace true with false.

    #1380525
    Jeffrey

    Unfortunately that didn’t do it…

    Do i replace 10 with the header element ID in both places? Tried both anyway ๐Ÿ™‚

    #1380715
    Leo
    Staff
    Customer Support

    Sorry the solution was for bbPress and not BuddyPress.

    Can you try this instead?

    add_filter( 'generate_header_element_display', function( $display, $element_id ) {
        if ( 10 === $element_id ) {
            if ( function_exists( 'is_buddypress' ) && is_buddypress() ) {
                return false;
            }
        }
    
        return $display;
    }, 10, 2 );

    Replace the first 10 only.

    #1380728
    Jeffrey

    Perfect!!!

    #1380799
    Leo
    Staff
    Customer Support

    Glad to hear ๐Ÿ™‚

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.