Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #838214

    Hello friends!

    I have a Woocommerce site and when people access there “my Account” page and navigate to under “Orders” There is a button that says “Start shopping” If you dont have any orders. This button takes you to the webbshop page that woocommerce sets up.

    But my shop is on a different page and different URL, how can i change the URL webbadress this button navigates to?

    Please help me! I will attach a picture of the button i mean!

    • This topic was modified 7 years, 3 months ago by Sankte.
    #838295

    Hey Sankte,
    Try adding this code to the end of your functions.php file in Appearance > Editor:

    /**
     * Changes the redirect URL for the Return To Shop button in the cart.
     *
     * @return string
     */
    function wc_empty_cart_redirect_url() {
    	return 'http://yourdomain.com/your-page/';
    }
    add_filter( 'woocommerce_return_to_shop_redirect', 'wc_empty_cart_redirect_url' );

    This will redirect to the URL specified in the code

    Best regards,
    Mike

    #838360

    Thanks alot Mike! It worked!

    You are a life savior!

    :)

    #838380

    Hi,
    Glad we were able to help, we will close this now. Thank you for using Enfold.

    Best regards,
    Mike

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘how can i change the URL this button takes me to?’ is closed to new replies.