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

gperez’s picture

Issue summary: View changes
gperez’s picture

Nevermind, I solved this doing the following:


$video_node = node_load($nid_video);
$brightcove_id = $video_node->field_video['und'][0]['brightcove_id'];

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)

k.dani’s picture

Status: Active » Closed (works as designed)