MainWP Community

Hide the Stripe payment request button on the cart page in WooCommerce

Hide the Stripe payment request button on the cart page in WooCommerce on your child site.

Snippet Type

Execute on Child Sites

Snippet

add_action( 'init', 'remove_stripe_payment_request_from_cart_20200608', 99 );
function remove_stripe_payment_request_from_cart_20200608() {
remove_action( 'woocommerce_proceed_to_checkout', array( WC_Stripe_Payment_Request::instance(), 'display_payment_request_button_html' ), 1 );
remove_action( 'woocommerce_proceed_to_checkout', array( WC_Stripe_Payment_Request::instance(), 'display_payment_request_button_separator_html' ), 2 );
}
1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.