Checkout: Filter – checkout_recurring_pmethods

Description

The checkout_recurring_pmethods filter hook let’s you add/remove from the available, recurring payment methods in the plugin by slug.

Usage

You can use the filter like this:

add_filter('checkout_recurring_pmethods', 'recurring_pmethods', 10, 1);

Arguments

  • $recurring_pmethods – An Array of recurring payment methods by slugs.

Example

function recurring_pmethods($recurring_pmethods = array()) {

//Append to the Array with the slug/name of your payment method you want to use for recurring
$recurring_pmethods[] = "mypmethod";

return $recurring_pmethods;
}

add_filter('checkout_recurring_pmethods', 'recurring_pmethods', 10, 1);

Earn Money by Referring People

Refer customers to us with your affiliate link and earn commission on sales from your link.

Get Started

Pin It on Pinterest

%d bloggers like this: