attachment_id3_data_meta_box( WP_Post $post )

Display fields for ID3 data


Description Description


Parameters Parameters

$post

(WP_Post) (Required) A post object.


Top ↑

Source Source

File: wp-admin/includes/meta-boxes.php

function attachment_id3_data_meta_box( $post ) {
	$meta = array();
	if ( ! empty( $post->ID ) ) {
		$meta = wp_get_attachment_metadata( $post->ID );
	}

	foreach ( wp_get_attachment_id3_keys( $post, 'edit' ) as $key => $label ) : ?>
	<p>
		<label for="title"><?php echo $label ?></label><br />
		<input type="text" name="id3_<?php echo esc_attr( $key ) ?>" id="id3_<?php echo esc_attr( $key ) ?>" class="large-text" value="<?php
			if ( ! empty( $meta[ $key ] ) ) {
				echo esc_attr( $meta[ $key ] );
			}
		?>" />
	</p>
	<?php
	endforeach;
}

Top ↑

Changelog Changelog

Changelog
Version Description
3.9.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.