woocommerce skip cart page code example
Example 1: woocommerce buy product skip cart
add_filter('add_to_cart_redirect', 'lw_add_to_cart_redirect');
function lw_add_to_cart_redirect() {
global $woocommerce;
$lw_redirect_checkout = $woocommerce->cart->get_checkout_url();
return $lw_redirect_checkout;
}
Example 2: skip cart page woocommerce
Skip Cart Page Go Straight to Checkout Page in WooCommerce