Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html> 
<html> 
<body> 
  
<button onclick="getPlaySpeed()" type="button">What is the playback speed?</button>
<button onclick="setPlaySpeed()" type="button">Set video to be play in slow motion</button>
<button onclick="setReverse()" type="button">Set video to be play in reverse</button>
  <br> 
<video id="video1" controls="controls">
  <source src="http://www.w3schools.com/tags/mov_bbb.mp4" type="video/mp4">
  <source src="http://www.w3schools.com/tags/mov_bbb.ogg" type="video/ogg">
  Your browser does not support HTML5 video.
</video>
<script>
myVid=document.getElementById("video1");
function getPlaySpeed()
  { 
  alert(myVid.playbackRate);
  } 
function setPlaySpeed()
  { 
  myVid.playbackRate=0.5;
  } 
  function setReverse()
  { 
  myVid.playbackRate=-1;
  } 
</script> 
<p>Video courtesy of <a href="http://www.bigbuckbunny.org/" target="_blank">Big Buck Bunny</a>.</p>
</body> 
</html>
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
anonymouspro
0viewers