get_attachment_taxonomies


get_attachment_taxonomies ( $attachment, $output = 'names' )

Parameters:
  • (int|array|object) $attachment Attachment ID, data array, or data object.
  • (string) $output Output type. 'names' to return an array of taxonomy names, or 'objects' to return an array of taxonomy objects. Default is 'names'.
Returns:
  • (array) Empty array on failure. List of taxonomies on success.
Defined at:
Change Log:
  • 4: .

Description

Retrieves taxonomies attached to given the attachment.

Related Functions

get_the_taxonomies, get_attachment_icon, get_attachment_icon_src, get_object_taxonomies, get_attachment_link

Top Google Results

User discussions

wpseek mobile