Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Looking for some guidance on how hide the header on more than just one template. Currently, I'm using the 'unless' condition to remove the header on a template we use for opt-ins, however, I had to create another template used for a video (page.masterclass-no-header) but I can't figure out how to add that template into the code. Everything I've tried removes the header from all templates including the homepage.
Here is what I currently have:
TYIA!
Solved! Go to the solution
This is an accepted solution.
This might seem like a bit of a hack but if your Unless statement is working for you I think you can just use an OR operator. This would get a bit much if you kept adding templates but for a couple it should be good:
{% unless template == "page.opt-in' or template == "new-template-you-want-to-exlude" %}
This is an accepted solution.
This might seem like a bit of a hack but if your Unless statement is working for you I think you can just use an OR operator. This would get a bit much if you kept adding templates but for a couple it should be good:
{% unless template == "page.opt-in' or template == "new-template-you-want-to-exlude" %}
Thank you, Steven! That worked! I appreciate it!
Hey Community! As we jump into 2025, we want to give a big shout-out to all of you wh...
By JasonH Jan 7, 2025Hey Community! As the holiday season unfolds, we want to extend heartfelt thanks to a...
By JasonH Dec 6, 2024Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024