Forums

[resolved] How to detect the FIRST (front) page? (5 posts)

  1. MephistoBS
    Member
    Posted 3 years ago #

    I didn't find a way to detect whether the user displays the first page of my front page or the second/third one.

    Background: I want to display navigation links "previous page/next page" only starting at the top of the second page and not at the top of the main page.

    Ciao, Meph

  2. Otto
    Tech Ninja
    Posted 3 years ago #

    The function is_paged() will return false on page 1 but true on pages 2 and up.

  3. Lester Chan
    Member
    Posted 3 years ago #

    does is_home() work?

  4. MephistoBS
    Member
    Posted 3 years ago #

    @Otto42: thanks, is_paged was the function I was searching for (don't ask me why I didn't found it by myself ;-)).

    @GamerZ: no. The function is_home returns true also on subsequent pages.

  5. pixeline
    Member
    Posted 3 years ago #

    is_front_page() is what you're after.

Topic Closed

This topic has been closed to new replies.

About this Topic