Plugin Author
royho
(@royho)
I’m sorry but I don’t understand how to do with add_filter. I know how to use add_filter with simple functions, no with classes.
Please, can you explain me how?
Thanks in advance,
Alessio
Plugin Author
royho
(@royho)
No difference. You can apply it the same way.
I think that I don’t understand how to use filters.
I tried like this but still not working.
function changeApplePay($stripe_params){
$stripe_params['label'] = get_bloginfo('name');
return $stripe_params;
}
add_filter('wc_stripe_apple_pay_single_params', 'changeApplePay');
Thanks,
Alessio
-
This reply was modified 6 years, 6 months ago by aleebraccia.
Hello,
@royho what was the resolution to this situation? The link you provided goes to a 404. I’m trying to workout how to remove “via woocommerce” on the Apple pay sheet.
Thanks!
Hello @tjfishsr,
The file linked on Github is line 302 of class-wc-stripe-apple-pay.php inside wp-content/plug-ins/woocommerce-gateway-stripe/includes.
If you find the right way to remove “via Woocommerce” label, please write here the solution (I’ve not found it yet).
Thanks,
Alessio
Plugin Author
royho
(@royho)
You can use this hook filter wc_stripe_payment_request_total_label
@royho, Thank you very much! That did the trick!
I tried, but it works only on “Processing” process, non after AJAX data load.
Removing the “Via Woocommerce” text from the confirm window seems to no longer work… is there a way to remove that text again?
Thank you!
Yes, it’s changed.
Now you need to filter “wc_stripe_payment_request_total_label_suffix”.