Switch language

wpseek.com
A WordPress-centric search engine for devs and theme authors




get_taxonomies [ WordPress Function ]

get_taxonomies ( $args = array(), $output = 'names', $operator = 'and' )
Parameters:
  • (array) $args An array of key => value arguments to match against the taxonomy objects.
  • (string) $output The type of output to return, either taxonomy 'names' or 'objects'. 'names' is the default.
  • (string) $operator The logical operation to perform. 'or' means only one element from the array needs to match; 'and' means all elements must match. The default is 'and'.
Uses:
  • $wp_taxonomies
See:
Returns:
  • (array) A list of taxonomy names or objects
Defined at:



Get a list of registered taxonomy objects.

Source


<?php
function get_taxonomies$args = array(), $output 'names'$operator 'and' ) {
    global 
$wp_taxonomies;

    
$field = ('names' == $output) ? 'name' false;

    return 
wp_filter_object_list($wp_taxonomies$args$operator$field);
}
?>

Examples [ wp-snippets.com ]

Top Google Search Results

More ...

0 User Note(s)

None yet. Be the first!

Add New ...



HTML5 Powered with CSS3 / Styling, Performance & Integration, and Semantics