Skip to:
Content
Pages
Categories
Search
Top
Bottom

redirect from /user/front to /user/activity


  • xpc33
    Participant

    @xpc33

    hi
    im trying, but i cant make it, actually i dont think im even close..
    whats the best way of redirecting from every user home page straight to activity?
    actually deleting then front would be okay too.

    thanks in advance

Viewing 3 replies - 1 through 3 (of 3 total)

  • Varun Dubey
    Participant

    @vapvarun


    xpc33
    Participant

    @xpc33

    Hi
    thanks but thats not what im trying to achieve. that’s already done with:

    if( !function_exists('custom_user_login_redirect') ) {
    function custom_user_login_redirect() {
    $redirect_to = '/members/me/friends/';
    return $redirect_to;
    }
    add_filter('login_redirect','custom_user_login_redirect',10,3);
    }

    what i want now is to redirect everyone from user dashboard, where there’s something like ‘Latest updates’ straight to another tab, permanent for all users.


    xpc33
    Participant

    @xpc33

    this did the trick. it doesnt need to redirect, but just changes landing page.

    //Set Default Tab to custom
    define('BP_DEFAULT_COMPONENT', 'custom' );
    add_filter( 'bp_is_active', function($retval, $component){
        if($component === 'custom') return true;
        return $retval;
    }, 10, 2 );
Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
Skip to toolbar