By Alex • 17. January 2024

This is my personal Cheat-Sheet for WooCommerce. My team and I work A LOT on WooCommerce Stores and therefor do a lot of changes and develop special stuff for our clients. Anyhow, most of these changes are in the end simple snippets which can be embedded in the functions.php file of any Child-Theme. You can use this stuff if you want, but be aware that it may break your store. So be careful and test it before going into production. Especially if you don't know what you are doing. From time to time I will ad more and more of our own stuff we collected and developed to this post. So check it out regularly 🙂 
Have fun! 

Move stripe button below checkout:

//move stripe button below checkout form
remove_action( 'woocommerce_checkout_before_customer_details', array( WC_Stripe_Payment_Request::instance(), 'display_payment_request_button_html' ), 1 ); //removes the button
remove_action( 'woocommerce_checkout_before_customer_details', array( WC_Stripe_Payment_Request::instance(), 'display_payment_request_button_separator_html' ), 2 ); // removes the separator under button
add_action( 'woocommerce_review_order_before_payment', array( WC_Stripe_Payment_Request::instance(), 'display_payment_request_button_html' ), 1 ); // adds the button before payments

What do you think about this?

Your email address will not be published. Required fields are marked

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}