Skip to:
Content
Pages
Categories
Search
Top
Bottom

Hide Default Subnav & Redirect


  • empressdianna
    Participant

    @empressdianna

    Hi I’m trying to redirect the user to a different page if they click on inbox. The problem is Inbox is the default submenu when the user clicks on messages. I can’t figure out how to change the default submenu or redirect the user to a different page. Here’s what I have so far that works, except it redirects the user to a 404 page. I’d like them to go to a different page. Any ideas?

    function bpfr_hide_tabs() {
    global $bp;
    
    	if ( pmpro_hasMembershipLevel('Basic') ) {
    		bp_core_remove_subnav_item( 'messages', 'inbox' );
     
    	} 
    	
    }
    add_action( 'bp_setup_nav', 'bpfr_hide_tabs', 15 );
  • You must be logged in to reply to this topic.
Skip to toolbar