Get your own website Result Size: 625 x 565
x
 
<!DOCTYPE html> 
<html> 
<body> 
<p>Can my browser play OGG files? 
  <span>
    <button onclick="supportType(event,'audio/ogg','vorbis')" type="button">Test</button>
  </span>
</p>
<script> 
function supportType(e,vidType,codType) { 
  var x = document.createElement("AUDIO");
  isSupp = x.canPlayType(vidType+';codecs="'+codType+'"');
  if (isSupp == "") {
    isSupp = "No";
  }
  e.target.parentNode.innerHTML = "Answer: " + isSupp;
} 
</script> 
</body> 
</html>