最后活跃于 1714504878

Malin's Avatar Malin 修订了这个 Gist 1714504877. 跳至此修订

1 file changed, 6 insertions

redirect-add-to-cart.php(file created)

@@ -0,0 +1,6 @@
1 + // for easycut.es
2 +
3 + function custom_redirect_to_cart_after_add_to_cart() {
4 + return wc_get_cart_url(); // Gets the URL of the cart page and redirects to it
5 + }
6 + add_filter('woocommerce_add_to_cart_redirect', 'custom_redirect_to_cart_after_add_to_cart');
更新 更早