Guest User

simple html5 video test pi 3

a guest
Mar 28th, 2016
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>Page Title</title>
  5. </head>
  6. <body>
  7.  
  8. <div onclick="playPause()">
  9. <video controls style="width:100%" id="cc1">
  10.   <source src="" type="video/mp4">
  11. </div>
  12.  
  13.  
  14.  
  15.  
  16.  
  17. http://www.w3schools.com/html/tryit.asp?filename=tryhtml_intro
  18. </video>
  19. <h1>Heading</h1>
  20. <p>https://www.youtube.com/feed/trending</p>
  21. <input type="text" id="cc2" value="1.5">
  22. <button onclick="myFunction()">Click me</button>
  23. <button onclick="myFunction(1)"><--</button>
  24. <br>
  25. <script>
  26. function myFunction(cc3) {
  27.     var cc2v = cc3?1:document.getElementById("cc2").value;
  28.     document.getElementById("cc1").playbackRate = cc2v;
  29. }
  30. function playPause() {
  31.     var pp2s = document.getElementById("cc1");
  32.     pp2s.paused ? pp2s.play() : pp2s.pause();
  33. }
  34. top.iframeResult.setAttribute('allowfullscreen', '');
  35. </script>
  36.  
  37. </body>
  38. </html>
Advertisement
Add Comment
Please, Sign In to add comment