Advertisement
Guest User

Untitled

a guest
Sep 18th, 2019
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.60 KB | None | 0 0
  1. <html>
  2.  
  3. <h1>Audio Player</h1>
  4.  
  5. <audio controls id="pod1" style="width:100%;">
  6.  
  7. <source src="MP3_FILE.mp3" type="audio/mpeg">
  8.  
  9. <!-- fallback -->
  10. <p>Your browser doesn't support HTML5 audio. Here is
  11. a <a href="MP3_FILE.mp3">link to the audio</a> instead.</p>
  12. </audio>
  13. <!-- skip link -->
  14. <span href="#pod1" onclick="skipAudio('pod1', '90')" class="skip-btn">>></span>
  15. <!-- Javascript -->
  16. <script>
  17. function skipAudio(plyr, skip) {
  18.  
  19. var plyr = document.getElementById(plyr);
  20.  
  21. var currentTime = plyr.currentTime;
  22. plyr.currentTime = skip;
  23.  
  24. }
  25. </script>
  26.  
  27. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement