CARVIEW |
Select Language
HTTP/2 200
server: nginx
date: Wed, 08 Oct 2025 03:41:28 GMT
content-type: text/html;charset=utf-8
vary: Accept-Encoding
cache-control: must-revalidate
alt-svc: h3=":443"; ma=86400
x-nc: MISS
content-encoding: gzip
#12516 (New function: get_taxonomies();)
– WordPress Trac
#2
#3
#4
#5
Opened 16 years ago
Closed 16 years ago
#12516 closed enhancement (fixed)
New function: get_taxonomies();
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 3.0 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Taxonomy | Keywords: | has-patch |
Focuses: | Cc: |
Description
WordPress has a function for retrieving all post types based on a certain criteria called get_post_types(). Taxonomies should have this kind of API too.
Attachments (2)
- get_taxonomies.diff (1.5 KB) - added by ptahdunbar 16 years ago.
- get_taxonomies.2.diff (1.3 KB) - added by scribu 16 years ago.
- return associative array
Download all attachments as: .zip
Change History (8)
@ptahdunbar
16 years ago
- Attachment get_taxonomies.diff added
#2
@scribu
16 years ago
Maybe add the $output parameter to get_object_taxonomies() instead of adding a new function.
#3
@scribu
16 years ago
- Keywords 2nd-opinion removed
- Milestone changed from Unassigned to 3.1
After more thought, get_taxonomies() would be quite handy.
get_object_taxonomies(), along with the rest of the functions, could be made to use it.
+1
#4
@scribu
16 years ago
Rewrote the function, to avoid duplicate code.
Also, if $output is not 'names', the function returns an associative array: $tax_name => $taxobj
See get_taxonomies.2.diff
#5
@momo360modena
16 years ago
Nice idea ! Patch looks good.
Note: See
TracTickets for help on using
tickets.
I'm not sure this is needed, since you would use get_object_taxonomies() most of the time.