Javascript / Dreamweaver CS4 - 如何控制 .flv 播放器?
我需要一个解决方案来控制 Dreamweaver CS4 的 flv 播放器。我想我必须为此使用 javascript。当您单击 div 容器时,它应该启动视频,再次单击同一容器将停止视频。 - 顺便说一句,我使用 JQuery 框架..所以你可以压缩代码..谢谢!!
伪 javascript:
If played == 0
On Click "#acooldiv"
PlayVideo "object flv"
played = 1
If played == 1
On Click "#acooldiv"
StopVideo "object flv"
played = 0
StopVideo 应该将视频带回 0:00(因此它不是暂停,而是视频播放的重置)
I need a solution to control the flv player of Dreamweaver CS4.. I think I have to use javascript for this. When you click on a div container it should start the video, another click on the same container will stop the video. - BTW I use the JQuery framework.. so may you can compress the code.. Thanks!!
Pseudo javascript:
If played == 0
On Click "#acooldiv"
PlayVideo "object flv"
played = 1
If played == 1
On Click "#acooldiv"
StopVideo "object flv"
played = 0
StopVideo should bring the video back to 0:00 (so its not a pause its a reset of the video playing)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
抱歉,我不熟悉 Dreamweaver,但是为什么要在该程序中控制 flv 播放器呢?您不想在 (html) 网页中播放 flv 并通过 javascript 播放吗?
如果您的意思是在网页中播放 FLV:
您可以与 flv 播放器(参见此处)进行通信。但也许最好将这些播放/暂停功能嵌入到 flv 播放器本身中,因为它非常基本,并且可能大多数 flv 播放器已经具备了它。
Sorry I'm not familliar with Dreamweaver, but why you want to control the flv player in that program? Don't you want to play a flv when it's in the (html)webpage and play it via javascript?
If you mean play FLV when its in the webpage:
You can communicate with the flv player (see here). But maybe better to embed these play/pause features in the flv player itself, because it really basic and probably most flv players already have it.