• Resolved SjorsHijgenaar

    (@sjorshijgenaar)


    Hi all,

    I am trying to show a few divs right under the mainnav bar that show upcoming events. However, I want them only on the front page, but is_front_page() or is_home() aren’t working. How, can I set up a condition that loads the function only on the front_page of Zerif Lite’s theme?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hello,

    You can try this CSS:

    .home .customdiv {
        display: block;
    }
    .customdiv{
        display:none;
        }

    In place of “customdiv” add the div class that you are added and only want to show in homepage.

    I hope it will work.

    Thank You

    Thread Starter SjorsHijgenaar

    (@sjorshijgenaar)

    Simple solution, yet working perfectly! Thank you gouravwptech

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Get front_page URI’ is closed to new replies.