Dear developer(s),
I am using Travelify as a website theme and it looks great!
But I was wondering if it is possible to create pages where the theme stays the same, but where the header and footer are not shown. I.e. only the page contents are shown in the style of the theme, but displayed over the complete page.
The reason I would like this, is that I want to create a page in the Travelify style and show only the content on a public screen.
Just to be clear, there are only a few pages I want to use for this purpose, so I want to have the option to show or not show header and footer. Is this possible?
Thanks in advance,
Erwin
The Netherlands
There are two possible solutions how you can get this done:
-
You can create custom page template like it is described here.
-
Or you can remove header using CSS. For that you can target individual pages using their IDs. You can inspect your website source to find post/page IDs. Here is a basic example how you can use it:
/* This will hide header but will leave top menu in place */
.page-id-1027 .hgroup-wrap {
display: none;
}
/* This will hide header and menu */
.page-id-1027 #branding {
display: none;
}
/* This will remove footer including widget area if you have it enabled */
.page-id-1027 #footerarea {
display: none;
}
I have also added comments to this code and you need to need to use either first part or second part of code depending how much you want to remove. Third part of code is always the same.
Let me know if this helps.
Thanks for the suggestions, but I think I’ve found a third option:
Using a Custom CSS plugin I was able to insert the following custom CSS:
img.header-image {
display: none;
}
#main-nav {
display: none;
}
#footerarea {
display: none;
}
Header, menu and footer disappeared exactly as I wished. Could this solution do any harm to the theme, or can I keep on using this solution?
It’s the same thing as plugin targets the same elements but it outputs this CSS for each page individually. Different approach with the same results, so you can feel free to stick with it.
OK, thanks for thinking with me and thanks again for the fine theme!
Super service!