Blog

Restrict Payment Methods based on Cart Total

In this tutorial I will show you how to disable WooCommerce payment gateways based on cart total without use of any plugin.

Disable Payment Gateway for Specific Country

In this tutorial we are going to talk about country based payments in WooCommerce. Because it is a common case that some payment gateways may not work for specific countries.

In this tutorial I will show you how to condition it easily and without any plugins.

Here is what we are going to create:

restrict WooCommerce payment gateways by country selected
At the moment of writing this tutorial PayPal doesn’t work for Monaco. So let’s deactivate PayPal payment gateway for Monaco.

Add ID Column to Payment Methods Table

Sometimes when you work with payment gateways on your website, you need to know their IDs (slugs). In this tutorial I show how to add a column to the payment gateways table in WooCommerce settings using a small piece of code.

Here is our result:

Payment method ID column
“Misha Gateway” is a custom payment gateway we created in this tutorial.

Conditional Logic in WordPress Meta Boxes

In this tutorial I will explain you how to show or hide a field depending on a value of another field within a simple WordPress metabox.

Add Fields to Taxonomy Terms

Creating Custom Options Pages

Escaping Outputs. Ultimate Tutorial