It sometimes happens that the is_home() and is_archive() functions stop working in some Wordpress installs, so you can’t make use of them anymore. It has happened to me a few times and I’ve had a hard time replacing them with more complicated code. Fortunately, there’s one simple solution for this problem.
If calling is_home() or is_archive() doesn’t return the correct boolean value, then try using the wp_reset_query() Wordpress function before them.
Here’s an example:
<?php
wp_reset_query();
if(is_home()) echo’Welcome home!’;
?>
Please note this might also help if other functions stop working, like: is_category, in_category, is_tag, has_tag etc.
Let me know if this worked for you, because it works like charm for me on all my blogs.

















