StevoLopata

JW Player

Nov 19th, 2020 (edited)
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.31 KB | None | 0 0
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <html class='' xmlns='https://www.w3.org/1999/xhtml' xmlns:b='https://www.google.com/2005/gml/b' xmlns:data='https://www.google.com/2005/gml/data' xmlns:expr='https://www.google.com/2005/gml/expr'><head><style type='text/css'/><style type='text/css'>.fancybox-margin{margin-right:0px;}</style>
  3. <b:skin><![CDATA[
  4. ]]></b:skin></head><body><div style='clear:both;'/>
  5. <title>Player</title>
  6. <style>
  7. body{margin:0;padding:0; background: #000; font-family: helvetica, arial, sans-serif; color: #fff; font-size: 28px;}
  8. </style>
  9.  
  10. <b:section id='fixelements' showaddelement='no'/>
  11.  
  12. <script src='https://content.jwplatform.com/libraries/IDzF9Zmk.js'></script>
  13. <script>jwplayer.key='YOUR_KEY';</script>
  14.  
  15.  
  16. <div id="player">Loading the player...</div>
  17. <script>
  18. // Setup the player
  19. const player = jwplayer('player').setup({
  20. file: 'insert_m3u8_link',
  21. image: "https://image.url",
  22. width: "100%",
  23. height: "100%",
  24. skin: "glow",
  25. autostart: true,
  26. controls: true,
  27. volume: 100
  28. });
  29.  
  30. // Listen to an event
  31. // Call the API
  32. const bumpIt = () => {
  33. const vol = player.getVolume();
  34. player.setVolume(vol + 10);
  35. }
  36. document.querySelector('#bumpit').onclick = () => { bumpIt(); }
  37. </script>
  38. </body></html>
Add Comment
Please, Sign In to add comment