Aleš Sýkora / April 29, 2024 / 0 comments

WooPayments – change Credit card / debit card text

Post summary: If you want to change the text of payment method Credit card / debit card when using WooCommerce Payments official plugin, you can use Loco Translate or you can use small snippet below.

If you want to change the text of payment method Credit card / debit card when using WooCommerce Payments official plugin, you can use Loco Translate or you can use small snippet below.

WooPayments Credit card payment title before change
function gt_change_credit_debit_text( $translation, $text, $domain ) {
	if ( $domain == 'woocommerce-payments' && $text == 'Credit card / debit card' ) {
		$translation = 'Platební kartou'; //change to your needs
	}
	return $translation;
    
}
add_filter( 'gettext_woocommerce-payments', 'gt_change_credit_debit_text', 999, 3 );
WooPayments Credit card payment title after change

Fuel my passion for writing with a beer🍺

Your support not only makes me drunk but also greatly motivates me to continue creating content that helps. Cheers to more discoveries and shared success. 🍻

0 comments

Share Your Thoughts