Don't want to display the website Header on a Landing Page

I have recently created a page to be used as a landing page on my website, by creating a template specifically for use by this page. I have created this within Shopify and not using an external App like Zippify. I now want this page to be displayed with just the Logo at the top as an Image (which I have done) however I am unable to turn the header/menu’s off without turning them off across the entire site. We are using the Theme Alto Palto. I have also noticed that when trying to add the code that has been suggested to be able to do this within Theme.Liquid that there are a number of errors at the bottom that weren’t previously there. If I do try to add any code now it will not allow me to and displays an error message when saving. Any advice would be appreciated.

Hey @user963

Attach the URL of your landing page as well along with your post so other users can help you out.

Best,
Moeed

This is my website but it keeps displaying “An error occurred: Sorry you cannot post a link to that host.’

the website is we are halo health .com (I’ve put spaces so someone can read it)

and the rest is pages/menopause-brain-fog

Hey @user963

Follow these Steps:

  1. Go to Online Store
  2. Edit Code
  3. Find theme.liquid file
  4. Add the following code in the bottom of the file above </ body> tag
{% if page.handle == 'menopause-brain-fog' %}
<style>
.site-header {
    display: none !important;
}
</style>
{% endif %}

RESULT:

If I managed to help you then a Like would be truly appreciated.

Best,
Moeed

Thank you - It’s worked! I’ve wasted hours on this. Should’ve come here in the first place you are all so helpful.

Glad to hear it worked for you. Don’t forget to Mark it as Solution so it can be helpful for others too.

Cheers,
Moeed

The errors showing up in theme.liquid might mean someone edited it before and left broken code, or you’ve got a syntax issue from a previous change. Try reverting theme.liquid to an older version from the theme editor’s version history and see if those errors disappear first. Once that’s clean you can add conditional code to hide the header on your specific template, but fix the broken file before adding anything new or it’ll just keep erroring out.