Last active
January 2, 2023 09:54
-
-
Save dennisnissle/8d5ca804fcdc3c33ff75db841b75b3c5 to your computer and use it in GitHub Desktop.
Switch payment and order wrap within Germanized checkout
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'after_setup_theme', 'my_child_adjust_checkout', 1000 ); | |
function my_child_adjust_checkout() { | |
remove_action( 'woocommerce_checkout_order_review', 'woocommerce_order_review', 20 ); | |
remove_action( 'woocommerce_checkout_order_review', 'woocommerce_checkout_payment', 10 ); | |
add_action( 'woocommerce_checkout_order_review', 'woocommerce_order_review', 10 ); | |
add_action( 'woocommerce_checkout_order_review', 'woocommerce_checkout_payment', 20 ); | |
} | |
add_filter( 'woocommerce_gzd_insert_order_submit_fallback', '__return_false' ); | |
add_filter( 'wc_gzd_checkout_params', 'my_child_prevent_gzd_checkout_heading_switch', 10 ); | |
function my_child_prevent_gzd_checkout_heading_switch( $params ) { | |
$params['adjust_heading'] = false; | |
return $params; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment