Error youtube shortcode

I have the following youtube.html shortcode under /layout/shortcodes/:

<div class="embed video-player">
<iframe class="youtube-player" type="text/html" width="800" height="400" src="{{ index .Params 0 }}" allowfullscreen frameborder="0">

I set into a page (md file) the following:

{{< youtube string >}} where the string is the value after v on YouTube.

It worked, and I don’t know what happened, but on the web page, a box appears as the image I attached.

The webpage is About me | NicFab Notes.
I don’t see any error from the console.
Any help?

Trying with other YouTube videos, I realized it depends on the video.
It works by using other videos.

The video’s uploader can set if they want the video to be available to embeds. Also if the video is set to private you might not be able to use it. The error points to one of these cases.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.