Title: calling categories
Last modified: August 19, 2016

---

# calling categories

 *  [ronchicago](https://wordpress.org/support/users/ronchicago/)
 * (@ronchicago)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/calling-categories/)
 * i already have 60+ categories and that should not change except category (24).
   my category.php is set up to call categories by naming each category via an array
   below…
 *     ```
       <?php $this_category = get_category($cat);
       // echo $this_category->cat_ID; ?>
       <?php if ( is_category(array(212, 255, 258, 251, 252, // products
                                    2232, 2233, 2234) //designers )) ?>
       ```
   
 * with this setup, every time i add a category i am adding an ID to the array. 
   i now expect to add a large # of children (designers = 2232, 2233, 2234) to a
   parent category (designer = 24). is there a syntax like childof= for the designer(
   24) category ? not sure how to write with current setup.

Viewing 1 replies (of 1 total)

 *  Thread Starter [ronchicago](https://wordpress.org/support/users/ronchicago/)
 * (@ronchicago)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/calling-categories/#post-1435069)
 * tried this but getting an error = parse error: syntax error, unexpected ‘=’, 
   expecting ‘)’…
 *     ```
       <?php if ( is_category(array(212, 255, 258, 251, 252&childof=24)
        )) ?>
       ```
   

Viewing 1 replies (of 1 total)

The topic ‘calling categories’ is closed to new replies.

## Tags

 * [category](https://wordpress.org/support/topic-tag/category/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 1 participant
 * Last reply from: [ronchicago](https://wordpress.org/support/users/ronchicago/)
 * Last activity: [16 years, 4 months ago](https://wordpress.org/support/topic/calling-categories/#post-1435069)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
