Home / Admin / WP Simple Pay: Add Custom CSS Classes to the Payment Button
Duplicate Snippet

Embed Snippet on Your Site

WP Simple Pay: Add Custom CSS Classes to the Payment Button

"Payment Button" refers to the button that launches an On-site Overlay or Stripe Checkout Payment Form.

Code Preview
php
<?php
/**
 * @link https://library.wpcode.com/snippet/j57zm12g/
 */
add_filter(
	'simpay_payment_button_class',
	/**
	 * @param array $classes List of class names.
	 * @return array
	 */
	function( $classes ) {
		$classes[] = 'my-button-class-1';
		$classes[] = 'my-button-class-2';
		return $classes;
	}
);

Comments

Add a Comment