wp_list_cats

Lists categories.

Description

(false|null|string) wp_list_cats( (string) $args = '' ); 

Returns (false|null|string)

Parameters (1)

0. $args — Optional. (string) => ''
The args.

Usage

  1. if ( !function_exists( 'wp_list_cats' ) ) { 
  2. require_once ABSPATH . WPINC . '/deprecated.php'; 
  3.  
  4. // The args. 
  5. $args = ''; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = wp_list_cats($args); 
  9.  

Defined (1)

The function is defined in the following location(s).

/wp-includes/deprecated.php  
  1. function wp_list_cats($args = '') { 
  2. _deprecated_function( __FUNCTION__, '2.1.0', 'wp_list_categories()' ); 
  3.  
  4. $r = wp_parse_args( $args ); 
  5.  
  6. // Map to new names. 
  7. if ( isset($r['optionall']) && isset($r['all'])) 
  8. $r['show_option_all'] = $r['all']; 
  9. if ( isset($r['sort_column']) ) 
  10. $r['orderby'] = $r['sort_column']; 
  11. if ( isset($r['sort_order']) ) 
  12. $r['order'] = $r['sort_order']; 
  13. if ( isset($r['optiondates']) ) 
  14. $r['show_last_update'] = $r['optiondates']; 
  15. if ( isset($r['optioncount']) ) 
  16. $r['show_count'] = $r['optioncount']; 
  17. if ( isset($r['list']) ) 
  18. $r['style'] = $r['list'] ? 'list' : 'break'; 
  19. $r['title_li'] = ''; 
  20.  
  21. return wp_list_categories($r);