Vendor login after

We're shifting our Forum based support to a more dedicated support system!

We'll be closing our Forum support from 10th June, 2020 and move to Email Support assistance.

  • If you are a WCFM premium add-ons user, contact us- here
  • Want to know more before buying our add-ons? Send Pre sale queries- here
  • If you are a WCFM free user, please open a support ticket at WordPress.org
  • For WCFM App related queries, reach us- here
From now the forum will be read-only!

Viewing 1 reply thread
  • Author
    Posts
    • #94161
      ozkancol
      Participant

      i want to do vendor login after redirect homepage.
      Now when vendor login redirect store-manager
      please help

    • #96278
      Sushobhan
      Keymaster

      You can use the following code –

      function redirect_vendor_to_homepage($redirect_to, $user) {
          if($user && in_array( 'wcfm_vendor', $user->roles ) ) return home_url();
          return $redirect_to;
      }
      add_filter( 'wcfm_login_redirect', 'redirect_vendor_to_homepage', 10, 2 );

      Add this code to your child theme’s functions.php

      In case you do not have child theme then add code using this plugin – https://wordpress.org/plugins/code-snippets/

Viewing 1 reply thread
  • The topic ‘Vendor login after’ is closed to new replies.