Skip to content

Instantly share code, notes, and snippets.

@BurlesonBrad
Created January 25, 2016 00:31
Show Gist options
  • Save BurlesonBrad/7ef94ece00acb441270b to your computer and use it in GitHub Desktop.
Save BurlesonBrad/7ef94ece00acb441270b to your computer and use it in GitHub Desktop.
For Robin
/** Robin, you can add these lines to your child theme's functions.php file
* If you're NOT using a child theme, please copy / paste this link
* https://github.com/woothemes/theme-customisations/archive/master.zip
* and use that plugin to make custimizations like this one to your theme
* Best wishes Robin
**/
add_filter ('woocommerce_add_to_cart_redirect', 'woo_redirect_to_checkout');
function woo_redirect_to_checkout() {
$checkout_url = WC()->cart->get_checkout_url();
return $checkout_url;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment