WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want the portfolio items to be arranged in custom order (based on the category descriptions which I use number values to order)

Current order

<ul id="portfolio-cats" class="filter clearfix">
        <li class="sort"><?php _e('Sort Items','themename'); ?>:</li>
        <li><a href="#all" rel="all" class="active"><span><?php _e('All', 'themename'); ?></span></a></li>
        foreach ($cats as $cat ) : ?>
        <li><a href="#<?php echo $cat->slug; ?>" rel="<?php echo $cat->slug; ?>"><span><?php echo $cat->name; ?></span></a></li>
        <?php endforeach; ?>

If I have 3 taxonomies named Gender, Age, Height.

I want the filter beside "All" to display them in above order, based on the taxonomy description.

Gender Desc "1", Age Desc "2" etc.

I want to to this on mass scale so not just 3 taxonomies, hence the need to number them.

share|improve this question
up vote 0 down vote accepted

You could use this plugin instead of trying to use the description field. It's very lightweight and uses drag-and-drop ordering on the admin end. Then you just orderby => term_order when grabbing your terms.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.