place.html 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8" />
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  6. <meta http-equiv="X-UA-Compatible" content="ie=edge" />
  7. <link rel="stylesheet" href="style/reset.css" />
  8. <link rel="stylesheet" href="style/public.css" />
  9. <link rel="stylesheet" href="style/place.css" />
  10. <link rel="stylesheet" href="font/iconfont.css" />
  11. <title>Document</title>
  12. </head>
  13. <body>
  14. <header class="title">
  15. <i class="iconfont iconbangonglou"></i>
  16. 重点场所
  17. </header>
  18. <div class="line"></div>
  19. <section class="s1">
  20. <main class="video-ctrl">
  21. <video
  22. id="testPlayer"
  23. poster=""
  24. controls
  25. playsInline
  26. webkit-playsinline
  27. autoplay="autoplay"
  28. >
  29. <source
  30. src="http://gz2play.95787.com/sx/gnFe37Och0oyb12RvJTMumpdG.m3u8"
  31. type="application/x-mpegURL"
  32. />
  33. </video>
  34. </main>
  35. <div class="line"></div>
  36. <main class="video-ctrl">
  37. <video src="./video/2.Ogg" loop="loop" autoplay="autoplay"></video>
  38. </main>
  39. <div class="line"></div>
  40. <main class="video-ctrl">
  41. <video src="./video/4.Ogg" loop="loop" autoplay="autoplay"></video>
  42. </main>
  43. </section>
  44. <script src="js/ezuikit.js"></script>
  45. <script>
  46. var player = new EZUIPlayer("testPlayer");
  47. player.on("error", function() {
  48. console.log("error");
  49. });
  50. player.on("play", function() {
  51. console.log("play");
  52. });
  53. player.on("pause", function() {
  54. console.log("pause");
  55. });
  56. Array.from(document.querySelectorAll(".s1 .video-ctrl")).forEach(
  57. (dom, index) => {
  58. dom.addEventListener("click", e => {
  59. console.log("placeClickHandle", index);
  60. window.placeClickHandle && window.placeClickHandle(index);
  61. });
  62. }
  63. );
  64. </script>
  65. </body>
  66. </html>