Homepage Redirect for Supply Theme

ac5a
Tourist
8 0 2

Hi, 

I would like the buyers to be directed to a collection page when they type in our store's URL instead of going to the homepage. 

 

How can I make this change? I tried looking in Supply's index file and it says 

{{ content_for_index }}

but there is no section named that. 

 

Any help is appreciated! 

0 Likes
LitExtension
Shopify Partner
1200 154 215

This is not possible, because the collection object only works when you go to the collection page page. So when on home page and show collection page, it won't work.
You can just use JS so that when the customer goes to the home page, they will be automatically redirected to the collection page.
Refer https://www.w3schools.com/jsref/met_win_open.asp
Ex: window.open('link', '_parent');

LitExtension - Shopping Cart Migration Expert
If our answer is helpful then please accept as solution!
Are you looking for a solution to migrate to Shopify? Contact us for further assistance.
Try our FREE DEMO now!
0 Likes
ac5a
Tourist
8 0 2

Hi LitExtension, 

 

If I have the URL of the collection page I want it to go, can I tell it to redirect to that? 

 

Thanks

0 Likes
LitExtension
Shopify Partner
1200 154 215

Yes you can add code in theme.liquid file:
<script>
// collection/all can be changed to the link collection you want, ex: collection/abc
window.open('collection/all', '_parent');
</script>

LitExtension - Shopping Cart Migration Expert
If our answer is helpful then please accept as solution!
Are you looking for a solution to migrate to Shopify? Contact us for further assistance.
Try our FREE DEMO now!
0 Likes
ac5a
Tourist
8 0 2

Thanks for the suggestion, unfortunately

<script>
// collection/all can be changed to the link collection you want, ex: collection/abc
window.open('collection/all', '_parent');
</script>

did not work. 

 

Any other ideas? 

0 Likes