This topic contains 3 reply and 2 voices, and was last updated by Nayem 4 years, 5 months ago
Viewing 3 Posts - 1 through 3 (of 3 total)
Author Posts
May 2, 2015 at 1:57 pm 42917
Nayem At present when a new seller signs up or logs in they are redirected to the My Account page. Would it not be more logical to redirect them to the Seller Dashboard? - I think the settings tab would be best place to send them. Can this be done? Thanks
May 2, 2015 at 2:28 pm 42920
Nayem Nayem

Hello Paul,

If you want to redirect seller to his dashboard after login then use this code in your child theme function.php file-

add_filter( 'woocommerce_login_redirect', 'ckc_login_redirect', 10, 2 );

function ckc_login_redirect( $redirect_url, $user ) {
    // Change this to the url to Updates page

    if( $user->roles[0] == 'seller' ) {
        return dokan_get_navigation_url(‘dashboard’);   
    }

return $redirect_url;
}

Thanks.

May 3, 2015 at 6:25 am 42945
Paul Paul

Thanks

That worked perfectly.

May 4, 2015 at 10:37 am 42972
Nayem Nayem This reply has been marked as private.
Viewing 3 Posts - 1 through 3 (of 3 total)