WordPress at a glance
function is not described

get_taxonomies_for_attachments() WP 3.5.0

Retrieves all of the taxonomy names that are registered for attachments.

Handles mime-type-specific taxonomies such as attachment:image and attachment:video.

  • See: get_taxonomies()

No Hooks.

Return

Array. The names of all taxonomy of $object_type.

Usage

get_taxonomies_for_attachments( $output );
$output(string)
The type of taxonomy output to return. Accepts 'names' or 'objects'.
Default: 'names'

Code of get taxonomies for attachments: wp-includes/media.php VER 5.0.3

<?php
function get_taxonomies_for_attachments( $output = 'names' ) {
	$taxonomies = array();
	foreach ( get_taxonomies( array(), 'objects' ) as $taxonomy ) {
		foreach ( $taxonomy->object_type as $object_type ) {
			if ( 'attachment' == $object_type || 0 === strpos( $object_type, 'attachment:' ) ) {
				if ( 'names' == $output )
					$taxonomies[] = $taxonomy->name;
				else
					$taxonomies[ $taxonomy->name ] = $taxonomy;
				break;
			}
		}
	}

	return $taxonomies;
}