Just Gadgets » Featured, General » in_category placeholder entry
Share |

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.

in_category placeholder entry

So if you want the same text to be applied to the category AND all its sub-categories, you’ll have to list them all. Syntax like in_category(2,11) is not allowed. You’ll have to use PHP || (logical OR) && (logical AND) in the expression.

Related posts:

  1. Firebug – a usefull Firefox Add-on
spersian is very hot on

in_category placeholder entry. Unfortunately, in_category doesn't understand category ... is a child of category 2 (fruits), in_category('2') will return FALSE when viewing post ... read more...
Tags: spersian, gadgets,

hi display some random posts

Using the code given here you can display five posts in random order ... in_category placeholder entry. hi display some random posts. Using the code given here you ... read more...
Tags: display, random, posts, wordpress,

November 20th, 2008 Tags: No Comment

Leave your response!

Add your comment below, or trackback from your own site. You can also subscribe to these comments via RSS.

Be nice. Keep it clean. Stay on topic. No spam.

You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

This is a Gravatar-enabled weblog. To get your own globally-recognized-avatar, please register at Gravatar.