function emvideo_google_duration in Embedded Media Field 6
Same name and namespace in other branches
- 6.3 contrib/emvideo/providers/google.inc \emvideo_google_duration()
hook emvideo_PROVIDER_duration($item) Returns the duration of the video in seconds.
Parameters
$item: The video item itself, which needs the $data array. @return The duration of the video in seconds.
File
- contrib/
emvideo/ providers/ google.inc, line 169 - This include processes Google.com media files for use by emfield.module
Code
function emvideo_google_duration($item) {
if (!isset($item['data']['emvideo_data_version'])) {
$item['data'] = emvideo_google_data(NULL, $item);
}
return isset($item['data']['duration']) ? $item['data']['duration'] : 0;
}