Support » Developing with WordPress » Trouble changing url of a button

  • Resolved woodbox


    I would like to change the “return to shop” button url to go to my homepage. I can’t for the life of me figure where in wordpress database to edit this. Any help is greatly appreciated.

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hello,

    This can be done in two ways, 1) with your theme’s functions.php file or 2) By using jQuery Code.

    Please place below code in your active theme’s functions.php file at the end.

    function woodbox_change_return_shop_url() {
    return home_url();
    add_filter( 'woocommerce_return_to_shop_redirect', 'woodbox_change_return_shop_url' );


    Use jquery Code Snippet.

      $(".return-to-shop a.wc-backward").click(function(){
        $(".wc-backward").attr("href", "");

    Hope this helps.


    • This reply was modified 2 years, 9 months ago by Kartik Shukla.
    Thread Starter woodbox



    That worked great
    Thank You so much!

    Happy to help!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Trouble changing url of a button’ is closed to new replies.