开发者

How to manipulate an embedded player with time slider?

开发者 https://www.devze.com 2023-01-31 12:51 出处:网络
I am now using an embedded Windows Media Player (tutorial) and I can manipulate with time slider 开发者_JS百科through Javascript. But then I discovered the Jlembed plugin for jQuery and thought it sol

I am now using an embedded Windows Media Player (tutorial) and I can manipulate with time slider 开发者_JS百科through Javascript. But then I discovered the Jlembed plugin for jQuery and thought it solves all my problems because of the different platforms, etc.

But after I spent a few hours in setting things up I relized that it does not have functions like setCurrentTime or getCurrentTime and these functions are most important for my type of project.

Is there a way to achieve this functionallity with Jlembed?


As far as I know, Windows Media Player does not support the type of interaction you're trying to achieve with it's embedded player. I did not include any javascript functions for Windows Media Player because it is not necessary. jlEmbed does not affect your ability to control the embedded player with javascript. So, if Windows Media Player supports a particular script, jlEmbed supports it also.

If there is a javascript API for WMP please point me in that direction and I will add better support for it, but I don't think it exists. However, if one does exist, jlEmbed will not prevent you from scripting as would normally be done.

I spent a great deal of time on the YouTube support, but only because I had to. Otherwise, it would have been much more difficult to control the YouTube player, which is the most popular and widely available media player on the web.

Only a small percentage of users will actually be able to use your embedded WMP presentation. The YouTube player is compatible with any browser that supports Flash. You would be better off creating a custom 'chromeless' YouTube player than using WMP for your presentation. An even better alternative would be to use Flash to make your video presentation.


According to the documentation, the following functions exist that might help:

  • jlembed_seekTo(playerId, seconds, allowSeekAhead)
  • jlembed_getCurrentTime(playerId)

Hope that helps!

0

精彩评论

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

关注公众号