Video function: options not recognized

Hi there,

I try to embed a youtube video with the following code in my template:

<?= video($video->url(), ['enablejsapi' => '1'], ['class' => 'video']) ?>

The iframe is created correctly, but the options are missing:

<iframe allowfullscreen="" class="video" src="https://youtube.com/embed/XYZ"></iframe>

Any clues? I even tried building the option array via array('enablejsapi' => '1') but that didn’t work either.

I’m not that familiar with PHP, maybe I’m doing something fundamentally wrong?

This should work:

<?= video($video->url(), ['youtube' => ['enablejsapi' => 1]], ['class' => 'video']) ?>

…and it does! Thank you! :grinning: