public function TED::iframe in Video Filter 8
HTML5 video (iframe).
Overrides VideoFilterBase::iframe
File
- src/
Plugin/ VideoFilter/ TED.php, line 33
Class
- TED
- Provides TED codec for Video Filter.
Namespace
Drupal\video_filter\Plugin\VideoFilterCode
public function iframe($video) {
$video_id = $video['codec']['matches'][3];
if (empty($video_id)) {
$video_id = $video['codec']['matches'][1];
}
return [
'src' => '//embed-ssl.ted.com/talks/' . $video_id . '.html',
'properties' => [
'webkitAllowFullScreen' => 'true',
'mozallowfullscreen' => 'true',
'allowFullScreen' => 'true',
'scrolling' => 'no',
],
];
}