Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi.
I'm trying and trying but I found no way to get the brightcove id of my current video player.
I have a player properly set, a content type for videos that implements the BC widget field, and a view that retrieves the widget and also metadata.
Note my videos belongs to "orders" content type. So, i'm listing all videos in a given order, doing something like this:
foreach($rows as $key => $val){
if( $val["nid"] == $nid_video){
var_dump($val);
};
}
With this, i'm getting a player. Also doing: echo $val['field_video_1']. But how can i get the brightcove id?
I need it to know how long the video is. Like this:
$video_class = new VideoBrightcove($bc_video_id);
$time = $video_class->getBrightcoveTime();
Thanks in advance.
Comments
Comment #1
gperez CreditAttribution: gperez commentedComment #2
gperez CreditAttribution: gperez commentedNevermind, I solved this doing the following:
I have the ID there since I saved it after uploading the video to Brightcove. .
(However notice older versions of Brightcove module had the brightcove_id available for Views module. Don't know why the removed that from metadata)
Comment #3
k.dani CreditAttribution: k.dani commented