DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Snippets has posted 5883 posts at DZone. View Full User Profile

List Categories

10.10.2008
| 3149 views |
  • submit to reddit
        // List categories in Wordpress

<?php wp_list_categories('arguments'); ?>  

$defaults = array(
'show_option_all' => '', 
'orderby' => 'name', 
'order' => 'ASC', 
'show_last_update' => 0, 
'style' => 'list',
'show_count' => 0, 
'hide_empty' => 1, 
'use_desc_for_title' => 1, 
'child_of' => 0, 
'feed' => '', 
'feed_image' => '', 
'exclude' => '', 
'hierarchical' => true, 
'title_li' => __('Categories'), 
'echo' => 1,
'depth' => 0
);