/** * Plugin Name: WP Simple Pay – Custom Smart Tags */ add_filter( ‘simpay_payment_details_template_tags’, function( $smart_tags ) { $smart_tags[] = ‘fee-recovery-amount’; $smart_tags[] = ‘pre-fee-amount’; return $smart_tags; } ); add_filter( ‘simpay_payment_confirmation_template_tag_fee-recovery-amount’, function( $value, $payment_confirmation_data ) { $object = current( $payment_confirmation_data[‘paymentintents’] );…Continue reading
add_filter( ‘simpay_get_paymentintent_args_from_payment_form_request’, function( $args ) { $args[‘metadata’] = array_map( function( $value ) { // If the value is `on` or `off`, change it. Otherwise return the normal value. if ( ‘off’ === $value ) { return ‘No’; } else if…Continue reading
add_filter( ‘wfea_price_display’, function ( $price_display, $min, $max, $currency ) { $event_id= get_post()->ID; if ( $event_id == 1234 ) { $min = $min – 10; $max = $max – 10; } if ( $min == $max ) { $price_display = $min;…Continue reading
add_filter( ‘wfea_price_display’, function ( $price_display, $min, $max, $currency ) { return $price_display . ‘ (Discounts available at checkout)’; }, 10, 4 );Continue reading
add_filter( ‘wfea_strip_eb_inline_styles’, ‘__return_false’ );Continue reading
add_filter(‘wfea_currency_symbols’, function ($currency_symbols) { $currency_symbols[‘CAD’] = ‘CAD$’; return $currency_symbols; } );Continue reading
add_filter( ‘wfea_age_restriction’, function ( $output, $age ) { if ( ‘all_ages’ === $age ) { $output = ‘All ages’; } return $output; }, 10, // filter priority 2 // number of args to filter );Continue reading