开发者

youtube chromeless scaling player

开发者 https://www.devze.com 2023-01-23 08:17 出处:网络
Does anyone know how can I make a chromeless player scaling based on browser size like this: http://lab.veille.jp/elastic-youtube-player/

Does anyone know how can I make a chromeless player scaling based on browser size like this: http://lab.veille.jp/elastic-youtube-player/

I tried using this http://tutorialzine.com/2010/07/youtube-api-custom-player-jquery-css/ and make the player scalable with jQuery, but it suffers from performance loss and doesn't make the video rescale properly when the window开发者_如何学编程 gets resized.

Thanks!


You can use dirrect jquery API in order to change size of player

$('#video_quwebVjAEJA').height('50px')
$('#video_quwebVjAEJA').width('50px')

where '#video_quwebVjAEJA' - id of object tag

Please note that these new values must be less than native from attributes "width" and "height". So you can set maxSize in that one.

0

精彩评论

暂无评论...
验证码 换一张
取 消