Can not remove header and footer from homepage
-
Hello one and all.
I have created a fairly basic WordPress theme and uploaded it to the Themes directory. So currently i have a folder with style.css index.php, header.php & footer.php no sidebar yet as i only want to use one on my blog page, which hasn’t been uploaded yet.
The landing page is the only page that i don’t. want the header and footer to appear on
The problem i’m finding is that no matter how many times i try to write the conditional statements to remove header and footer.php it is never removed. Some code examples:
My index.
My header
My footer
I have tried putting statements in various places, i think my problem apart from being complete novice is i don`t understand which page i need to reference in the if statement.
I have tried:
<?php if( !is_page( ‘1’ ) ) : ?> {with various page numbers}<?php if( !is_home( ” ) ) : ?>
<?php if( !is_front_page( ” ) ) : ?>
Each time i have wrapped this around the code in the header and footer.
I hope this makes some sense to someone, and i have tried unsuccessfully to rectify this using existing posts.
Many thanks
Kark
- The topic ‘Can not remove header and footer from homepage’ is closed to new replies.