Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #5270

    Hi there,

    Thanks so much for such a wonderful WP theme! I would like to remove the header only from the Home page, and it will remain on the rest of the internal pages/posts of the site. I’ve perused several threads in an attempt to find the best solution that would work with this theme — to no avail. I thought I’d send an inquiry over to your support team for some guidance. I’m using a Frontpage Template with:

    > “Slideshow” element (pulling a pic w/ video link from the “Featured” section of the Home page)

    > Horizontal ruler

    > “Widgets” element (with 4-columns using HTML to link four separate boxes to the four key pages of the site)

    I was able to comment out the lower “footer” area and used the “Footer” widgets to customize that information. My clients want a very minimal landing page that focuses users to these key areas, but a site menu that is available once “inside” the site.

    Thanks so much for your help!

    G. Ratliff

    #49491

    Hey,

    you can use following conditional statement:

    <?php if(is_home() || is_front_page()) { ?>
    ....
    <?php } ?>

    to display code/text on the frontpage/homepage only. If you don’t want to display text/code on the frontpage use:

    <?php if(!is_home() || !is_front_page()) { ?>
    ....your code
    <?php } ?>

    #49492

    Dude,

    Hey. Thanks for the follow-up! I’m still acclimating to the PHP language and how the conditional statements need to reference properly. Can you give me a bit more guidance on which PHP file needs to get the statement? I thought I would be updating the header.php since I don’t want it to display on the frontpage. If this is true, I’m not envisioning how I’m supposed to add this code in with the existing string.

    I’m wanting to use this statement to remove header from Home page only:

    <?php if(!is_home() || !is_front_page()) { ?>

    ….your code???

    <?php } ?>

    Thanks again for your help,

    G. Ratliff

    #49493

    Dude,

    Got it! Thanks so much for your help! I was on the right track, and was only wrapping the conditional statement too high up in the code. User error, but understand now. Appreciate it!

    G.Ratliff

    #49494

    Glad you got it to work :)

Viewing 5 posts - 1 through 5 (of 5 total)

The topic ‘Removal of header only on Home page’ is closed to new replies.