Created
June 7, 2023 21:41
-
-
Save xardit/b47146070f068e15fd27e3a86732ab2e to your computer and use it in GitHub Desktop.
WP Woocommerce - Redirect ADD TO CART > CHECKOUT PAGE for faster checkout
This file contains hidden or 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 | |
// redirect Add To Cart > Checkout | |
add_filter ('woocommerce_add_to_cart_redirect', function( $url, $adding_to_cart ) { | |
return wc_get_checkout_url(); | |
}, 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment