Home Forums WC Vendors Pro Support Vendor Register redirect

NOTICE: We've Moved to a Ticket System for Support

As of August 31, 2017 (12am EST) our support forums will be retired (read-only), and we will be moving to a support ticket system.  This will allow us to better organize and answer support requests, and provide a more personalized experience as we assist our customers.

For the time being, we will leave our forums open for reading and learning while we work on creating a more robust Knowledge Base for everyone to use.

If you are a WC Vendors Pro customer please open a support ticket here. 

If you are a WC Vendors user please open a support ticket on the Wordpress.org forums.

The information on this forum is outdated and in most instances no longer relevant. Please be sure to check our documentation for the most up to date information.

https://docs.wcvendors.com/

Thank you to all of our customers!

 

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #59317
    Aaron Roessler
    Participant

    Shouldn’t this code work and redirect to the vendor pro dashboard products tab after the Vendor Application? I unchecked “Approve vendor applications manually” so they are automatically setup as Vendor. It’s just going to the main dashboard tab still.

    /* WC REGISTER REDIRECT */
    add_filter('woocommerce_registration_redirect', 'wcs_register_redirect');
    function wcs_register_redirect( $redirect ) {
         $redirect = 'https://reusesb.com/dashboard/product';
         return $redirect;
    }
    
    #59348
    Anna
    Member

    Hello,
    I am not sure if your theme is already re-directing your vendors, but this code below should work to direct to the Pro Dashboard:

    /* Redirect Vendors to Pro Vendor Dashboard on Login */
    add_filter('woocommerce_login_redirect', 'login_redirect', 10, 2);
    function login_redirect( $redirect_to, $user ) {
        if (class_exists('WCV_Vendors') && class_exists('WCVendors_Pro') && WCV_Vendors::is_vendor( $user->id ) ) {
            $redirect_to = get_permalink(WCVendors_Pro::get_option( 'dashboard_page_id' ));
        }
        return $redirect_to;
    }
    #59835
    Aaron Roessler
    Participant

    Ok that code works! but I want them to be directed to product tab. here: https://reusesb.com/dashboard/product

    I modified the code but still only goes to main dashboard tab.

    add_filter('woocommerce_login_redirect', 'login_redirect', 10, 2);
    function login_redirect( $redirect_to, $user ) {
        if (class_exists('WCV_Vendors') && class_exists('WCVendors_Pro') && WCV_Vendors::is_vendor( $user->id ) ) {
            $redirect_to =  'https://reusesb.com/dashboard/product';
        }
        return $redirect_to;
    }
Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘WC Vendors Pro Support’ is closed to new topics and replies.