You can embed different css for homepage by the following method:

You can use:
is_front_page()|| is_home()

Difference between both:

is_front_page() returns true if the user is on the page or page of posts that is set to the front page on Settings->Reading->Front page displays

So if you set about us as the front page then this condition will only be true if showing the about us page.

is_home() return true when on the posts list page, i.e the page that shows the latest 10 posts.

If the settings under Front page displays are set as default then the home page will return true for both is_front_page() and is_home()

An example of using is_home():

You have set your posts page to a page called blogs.
A user navigates there and in the header you want to show additional navigation
You could use is_home() to do this

LEAVE A REPLY