Tag Archives: wordpress

in_category placeholder entry

Unfortunately, in_category doesn’t understand category child-parent relationships. If, for example, category 11 (bananas) is a child of category 2 (fruits), in_category(’2′) will return FALSE when viewing post about bananas. So if you want the same text to be applied to … Continue reading

Posted in Featured, General | Tagged | Leave a comment

hi, display some random posts in WordPress

Using the code given here you can display five posts in random order on your WordPress Site. About the format you can adjust as you like, the number of posts is set by numberposts=5 <?php $rand_posts = get_posts(‘numberposts=5&orderby=rand’); foreach( $rand_posts … Continue reading

Posted in General | Tagged | Leave a comment