[wp-hackers] Can't use the same conditional tag twice?

Eric Marden wp at xentek.net
Tue Sep 1 00:41:37 UTC 2009


On Aug 30, 2009, at 10:37 PM, Bryan Harley wrote:
> <li class="<?php if ( is_home() ) { echo 'current_page_item'; } ?>"><a
> href="URLHERE">Welcome</a></li>
>
> <li class="<?php if ( is_front_page() ) { echo 'current_page_item'; }
> ?>"><a href="URLHERE">Welcome</a></li>
>



FYI: is_home() and is_front_page() aren't always equivalent and  
depending on the configuration of WordPress, can be testing different  
things:
http://codex.wordpress.org/Conditional_Tags


- Eric Marden
__________________________________
http://xentek.net/code/wordpress/







More information about the wp-hackers mailing list