可以禁用“在 Youtube 上观看"关联?

问题描述:

我正在构建一个应用程序,在其中嵌入视频和视频剪辑的特定部分.例如,它看起来像这样

I am building an app where I am embedding videos and specific sections of video clips. For example, it looks like this

<iframe width="640" height="360" src="https://www.youtube.com/embed/pftnJbQjSBA&modestbranding=1&showinfo=0&autoplay=1&controls=0&modestbranding=1&disablekb=1&rel=0&start=10&end=20" frameborder="0"></iframe>

是否可以禁用在 youtube 上观看"链接,以便用户最终不会导航到其他地方.明确地说,我只想在观看视频时控制流量(即不试图干扰广告或 YouTube 徽标).

Is it possible to disable "Watch on youtube" link so the user doesn't end up navigating elsewhere. Just to be clear, I only want to control the flow while the video is being watched (i.e not trying to interfere with ads or YouTube logo).

有可能,只需将 &modestbranding=1 添加到您的嵌入代码中即可.

It is possible, just add &modestbranding=1 to your embed code.

观看:https://www.youtube.com/watch?v=4NFgV_Et9gY一个>

例如

<object width="800" height="450" data="http://www.youtube.com/v/@Model.YoutubeId&rel=0&modestbranding=1"></object>

请注意,当用户的鼠标指针悬停在播放器上时,一个小的 YouTube 文本标签仍会显示在暂停的视频的右上角.

Note that a small YouTube text label will still display in the upper-right corner of a paused video when the user's mouse pointer hovers over the player.

详细了解 YouTube 的 iFrame Player API.