问题描述
这听起来可能很愚蠢,但我在网上查了一段时间,但找不到如何制作无铬的 YouTube 播放器.我正在制作一个网络应用程序,并且正在使用 YouTube JavaScript API.无论我在网上查找有关如何实际使播放器无铬的一些信息,它都只是为我提供了有关如何使用无铬播放器进行操作的信息.没有人解决这个问题(这似乎很明显),但我就是不知道该怎么做.有人可以向我解释一下怎么做(我需要在某处传递某个参数吗?)谢谢.
This may sound stupid but I looked online for some time and I could not find how to make a YouTube player chromeless. I am making a web app and I am using the YouTube JavaScript API. Wherever I look online for some information on how to actually make the player chromeless, it just gives me information on how to operate with a chromeless player. Nobody addresses this question (it seems to be obvious), but I just can't figure out how to do it. Could someone please explain to me how to do it (do I need to pass a certain parameter somewhere?) Thanks.
推荐答案
好吧,我想通了.因此,如果您像我一样使用 JavaScript(我相信它也适用于 AS3),只需编写apiplayer",而不是在 URL(您提供给 embedswf() 函数的那个)中写入视频 ID.然后,在视频播放器加载后,只需调用它的函数 cueVideo() (将要显示的视频的视频 ID 传递给它).这将使视频播放器无铬.
Alright, so I figured it out. So, if you are using JavaScript as I did (I believe it also works for AS3), simply, instead of writig the video ID in the URL (the one that you give to the embedswf() function), write "apiplayer". Then, after the video player has loaded, simply call the function cueVideo() on it (passing it the video ID of the video you want to show). This will make the video player chromeless.
这篇关于如何制作 YouTube 无铬播放器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!