Function: wp_get_media_creation_timestamp

wp_get_media_creation_timestamp( array $metadata )

Parse creation date from media metadata.

The getID3 library doesn't have a standard method for getting creation dates, so the location of this data can vary based on the MIME type.


Name Type(s) Default Value Description
$metadata array

The metadata returned by getID3::analyze().


integer | boolean

A UNIX timestamp for the media's creation date if available or a boolean FALSE if a timestamp could not be determined.

WordPress Developer Newsletter

Stay on top of the latest WordPress API changes, developer tool updates, security alerts and more.