Filtering issues | WordPress.org

[ad_1]

Plugin Author
WP Trio

(@wooelements)

Hello,

Thanks for reporting this issue.

It seems that the payment gateway plugins defines the payment methods dynamically (the ones with extra suffix) and Conditional Payments doesn’t detect them correctly.

To fix this you will need to register the custom payment methods with a WP filter:

<?php
add_filter( 'wcp_payment_method_options', function( $methods ) {
	// Register custom payment methods here
	$methods['custom_method_id'] = 'Custom method title';
	$methods['custom_method_id_2'] = 'Custom method title 2';

	return $methods;
} );

This will allow you to add new options to Disable / Enable payment methods select list. Just replace custom_method and Custom method title in the code with przelewy24_extra_154 and so on. You can add the snippet with Code Snippets or to your theme’s functions.php file.

Marking this as solved now but feel free to reopen if you need further help.

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer