本文实例讲述了基于js与flash实现的网站flv视频播放插件代码。分享给大家供大家参考。
具体实现代码如下:
<body>
<script src="video/swfobject.js" type="text/javascript"></script>
<script type="text/javascript">
var s1 = new SWFObject("video/flvplayer.swf", "single", "640", "240", "7");
s1.addParam("allowfullscreen", "true");
s1.addVariable("autostart", "true");
s1.addVariable("repeat", "true");
s1.addVariable("image", "preview.jpg");
s1.addVariable("file", "http://www.XXX.com/01.flv");
s1.addVariable("clicktext", "开始");
s1.write("player1");
s1.addVariable("width", "640");
s1.addVariable("height", "240");
</script>
</body>
</html>
完整实例代码点击此处本站下载。
希望本文所述对大家的web程序设计有所帮助。
新闻热点
疑难解答