Forums

2 loops on the homepage, static landing page (6 posts)

  1. gerhard
    Member
    Posted 1 year ago #

    Hi, I would like to create 2 loops on the homepage, one that will only show when you on the very 1st landing page of the site, so: "/" or "/blog/" or "/whatever/".

    This will work like a static homepage, but without the need for additional pages or settings in the back-end.

    is_home() and is_front_page() doesn't work, because as long as your on the normal home pages it will show that, and I just want this to work on the very 1st landing home page of the site.

    Any help will be greatly appreciated :)

  2. esmi
    Theme Diva & Forum Moderator
    Posted 1 year ago #

    is_home() and is_front_page() are both home page conditionals - ie they are true when on the 1st landing (posts and static, respectively) page of a site. On that basis, I'm not sure what it is that you're trying to do...

  3. gerhard
    Member
    Posted 1 year ago #

    If I use is_home() then whatever is in those tags will apply to "/", "/?paged=2", "/?paged=3", etc.

    I want something that will only apply to "/" or whatever the root of the blog is.

  4. esmi
    Theme Diva & Forum Moderator
    Posted 1 year ago #

    Try if( is_home() && !is_paged() )

  5. gerhard
    Member
    Posted 1 year ago #

    @esmi Thanks, I will try that when I get home tonight and will feed back on here :)

  6. gerhard
    Member
    Posted 1 year ago #

    Yay, this worked, thank you so much for the help :)

Topic Closed

This topic has been closed to new replies.

About this Topic