Answer the question
In order to leave comments, you need to log in
How to make the checkout process faster?
There will be 5-6 products in the store, it makes no sense to throw them into the basket first, then proceed to checkout. How to make it so that the client would immediately go to checkout by clicking on the selected product?
Answer the question
In order to leave comments, you need to log in
function skip_cart_and_redirection_to_checkout() {
if (is_cart()) {
wp_redirect(wc_get_checkout_url());
// wp_redirect( WC()->cart->get_checkout_url() ); для WC < 3
}
}
add_action('template_redirect', 'skip_cart_and_redirection_to_checkout');
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question