Hi,
I am looking to re-direct my continue shopping button back to my home page, rather than the all products page it goes to now. Please could someone advise how to do this?
I am using dawn theme version 9.
Thanks in advance!
Hi,
I am looking to re-direct my continue shopping button back to my home page, rather than the all products page it goes to now. Please could someone advise how to do this?
I am using dawn theme version 9.
Thanks in advance!
Thank you for reaching out to the shopify community.
To change the URL of the continue shopping button so that it redirects to home page, please follow the steps below:-
Go to your theme code editor and look for file named main-cart-items.liquid in Sections folder. There search for cart__empty-text (ctrl+f cart__empty-text).
Screen shot for reference
Now change the href of a tag to {{ routes.root_url }}.
Now the continue shopping button will redirect you to home page.
Please give it a try and let me know if this was helpful.
Thanks
thank you so much it was very helpful. I was able to follow instructions and fix what i needed
Hi! I tried this solution for Dawn theme 14 version and it does not work. The code keeps me on the cart page does not go to home page. Do you have an updated solution? Thank you
Hi @ESK315
Instead of changing href tag to {{ routes.root_url }}.
You can change it to {{ routes.collections_url }}.
Let me know if this helps!
Hi there, none of these seem to work anymore. No matter what I put in there, it keeps redirecting to the All Products page. Even if I put a meaningless string of code like “abcdef” it keeps doing the original function. I don’t know what they’ve done to the Dawn theme, as if them codes are just facades at this point.
Same with when I try to hide the Sale badge, it only hides them on the Product page and Homepage but not on the Collection pages. I’d appreciate if you could help me fix this. Thanks!
Hi,
Navigate to cart-drawer.liquid file in Snippets group.
Within the file, find {{ routes.all_products_collection_url }} and change it to {{ routes.root_url }}
This will now redirect the button to homepage. It is an HREF tag so you can add URLs within the inverted commas to customize it further if required.
For those of you coming to this fresh - you need to replace the path in two locations within the theme code:
In the Sections folder, find “main-cart-items.liquid”
In the Snippets folder, find “cart-drawer.liquid”
In each, find all href lines that contains {{ routes.all_products_collection_url }} and replace with {{ routes.root_url }}
May the odds be ever in your favor!