Image Metadata
-
how do you display image metadata information on the image.php and be able to control what displays and what is not.
the code i am using in the functions.php is,
function myMetaData($pic) { $html = ''; $meta = wp_get_attachment_metadata($pic); if($meta) { $html = ' <ul>'; foreach($meta['image_meta'] as $key => $value) { $html .= ' <li>' . $key . ': <strong>' . $value . '</strong></li> '; } $html .= '</ul> '; } return $html; }
and
<?php echo myMetaData($post->ID); >
in the image.phpI just only want to display certain metadata, not all of them.
- The topic ‘Image Metadata’ is closed to new replies.