In this post, we’ll show you how to hide payment methods based on product vendors in WooCommerce. If you have a multivendor platform, you can block a specific payment method for certain vendors. And the best part is that you don’t have to program anything. Just a few clicks, and you’ll be done.
We’ll do it using the WooCommerce Conditional Payment Gateways plugin. You can enable or disable any payment gateways based on information from cart, user details, product details, and dates.
Here are just some examples:
In this example, we’re using vendors created with Dokan. We’ll hide a payment method based on a Dokan product vendor.
You can download the plugin here:
Download WooCommerce Conditional Payment Gateways Plugin - or - Read more
Once you install and activate the plugin, you need to follow these simple steps:
1- Create a new condition for you payment gateways
First, you need to create a new condition for you payment gateways with the WooCommerce Conditional Payment Gateways plugin.
- Go to WooCommerce > Conditional Payment Methods.
- Tick the Enable conditions checkbox.
- Click Add condition to create a new condition.
2- Hide payment methods based on product vendor
Once you’re in the create condition form, you need to select the following values to hide payment methods based on product vendor.
- What happens when the conditions are met: Disable the payment method(s)
- Select the payment methods: Select the payment methods you’ll disable. PayPal, for example.
- If your gateway doesn’t appear, tick the My gateway doesn’t appear in the list checkbox and add the gateway.
- Condition 1: Vendor = Nancy West, for example.
- If you want to add another vendor, click Add ‘Or’ group and select the new condition.
- Publish the condition.
That’s really simple!
As you see, it’s really simple to hide payment gateways based on product vendor. You don’t need to program anything. With a few clicks, you can hide any payment method for specific product vendors.
You can download the plugin here:
Download WooCommerce Conditional Payment Gateways Plugin - or - Read more