1 Star 0 Fork 0

ppker/videojs-events-example

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
index.html 1.56 KB
一键复制 编辑 原始数据 按行查看 历史
Alejandro García Iglesias 提交于 2012-08-24 13:49 . Initial import.
<!doctype html>
<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en"> <![endif]-->
<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8" lang="en"> <![endif]-->
<!--[if IE 8]> <html class="no-js lt-ie9" lang="en"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Video.js events example</title>
<meta name="viewport" content="width=device-width">
<link rel="stylesheet" href="css/style.css">
<link href="http://vjs.zencdn.net/c/video-js.css" rel="stylesheet">
</head>
<body>
<!--[if lt IE 7]><p class=chromeframe>Your browser is <em>ancient!</em> <a href="http://browsehappy.com/">Upgrade to a different browser</a> or <a href="http://www.google.com/chromeframe/?redirect=true">install Google Chrome Frame</a> to experience this site.</p><![endif]-->
<div role="main">
<video id="my_video_1" class="video-js vjs-default-skin" controls
preload="auto" width="640" height="480">
<source src="Nikhil Banerjee-BBC performance.webm" type='video/mp4'>
</video>
</div>
<script src="http://vjs.zencdn.net/c/video.js"></script>
<script>
_V_("my_video_1").ready(function(){
var myPlayer = this;
myPlayer.addEvent('durationchange', function () {
myPlayer.currentTime(56);
myPlayer.play();
});
myPlayer.addEvent('timeupdate', function () {
if (myPlayer.currentTime() >= 60) {
myPlayer.pause();
}
})
});
</script>
</body>
</html>
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/ppker/videojs-events-example.git
[email protected]:ppker/videojs-events-example.git
ppker
videojs-events-example
videojs-events-example
master

搜索帮助