Redirect Customer To Specific Collection Based On Tag

archer223
Tourist
16 0 1

I found this code on one on the forums 

{% if customer.tags contains 'assc'%}

<script>window.location.href= '/collections/assc-members'</script>
{% endif %}

However, the issue with it is when you are logged in and you click on accounts, it keeps redirecting you back to the collection. What i want to do is if a customer logs into the website and has the tag assc, then they get redirected to assc-members page. But if they click on accounts, then they can go to the accounts page. Better yet when they login they have the option to either go the the accounts page or the assc members collection page.

 

Any help is greatly appreciated 

0 Likes