wp_get_attachment_id3_keys filter-hookWP 3.9.0

Filters the editable list of keys to look up data from an attachment's metadata.


add_filter( 'wp_get_attachment_id3_keys', 'wp_kama_get_attachment_id3_keys_filter', 10, 3 );

 * Function for `wp_get_attachment_id3_keys` filter-hook.
 * @param array   $fields     Key/value pairs of field keys to labels.
 * @param WP_Post $attachment Attachment object.
 * @param string  $context    The context. Accepts 'edit', 'display'.
 * @return array
function wp_kama_get_attachment_id3_keys_filter( $fields, $attachment, $context ){

	// filter...
	return $fields;
Key/value pairs of field keys to labels.
Attachment object.
The context. Accepts 'edit', 'display'.
Default: 'display'


Since 3.9.0 Introduced.

Where the hook is called

wp-includes/media.php 3197
return apply_filters( 'wp_get_attachment_id3_keys', $fields, $attachment, $context );

Where the hook is used in WordPress

Usage not found.