Title: Categories in a multidimensional array?
Last modified: August 19, 2016

---

# Categories in a multidimensional array?

 *  [gozlingo](https://wordpress.org/support/users/gozlingo/)
 * (@gozlingo)
 * [18 years, 2 months ago](https://wordpress.org/support/topic/categories-in-a-multidimensional-array/)
 * Hi,
 * I need to do some clever formatting on my categories which involves looping through
   each category and applying different styles.
 * Is there any way of retrieving the categories in a multidimensional array so 
   that I can deal with categories & subcategories?
 * Ideally I need the same as what the following function returns but I don’t want
   it already formatted for me in a list, I just want it in an array:
 * wp_list_categories(‘hide_empty=0&hierarchical=1&echo=0’);
 * Any ideas anyone?
 * Thanks,
    Oliver

The topic ‘Categories in a multidimensional array?’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 0 replies
 * 1 participant
 * Last reply from: [gozlingo](https://wordpress.org/support/users/gozlingo/)
 * Last activity: [18 years, 2 months ago](https://wordpress.org/support/topic/categories-in-a-multidimensional-array/)
 * Status: not a support question

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
