My front page is just a list of the posts separated by category. I’m working on a plugin that get the id of the post but needs to test if the user is currently on the front page:
if(is_front_page()){
do this thing
}
else {
do this other thing
}
problem is, on the post pages it returns true for is_front_page. I tried is_home but get the same result.
Turns out since the plugin output in the footer I just had to reset the query: wp_reset_query();