1.播放视频
<videowidth="1000px"height="400px"controls="controls">
<sourcesrc="../video/1.mp4">
</video>
2.播放音质
<audiosrc="../video/1.mp4"controls="controls">
</audio>
3.计算坐标
<!DOCTYPEhtml>
<htmllang="en">
<head>
<metacharset="UTF-8">
<title>test2</title>
<styletype="text/css">
body{
font-size:70%;
font-family:Verdana,Helvetica,Arial,Sans-Serif;
}
</style>
<scripttype="text/javascript">
functioncnvs_getCoordinates(e){
x=e.clientX;
y=e.clientY;
document.getElementById("testcnvs").innerHTML=x+","+y;
}
functioncnvs_clearCoordinates(){
document.getElementById("testcnvs").innerHTML="(x="+x+","+"y="+y+")";
}
</script>
</head>
<body>
<divstyle="float:left;width:300px;height:80px;background-color:#0000CC"onmouseover="cnvs_getCoordinates(event)"onmouseout="cnvs_clearCoordinates()">
</div>
<br>
<br>
<divid="testcnvs"></div>
</body>
</html>
效果如下: