95 lines
4.1 KiB
HTML
95 lines
4.1 KiB
HTML
<!doctype html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<title>Plyr - A simple HTML5 media player</title>
|
|
<meta name="description" content="A simple HTML5 media player with custom controls and WebVTT captions.">
|
|
<meta name="author" content="Sam Potts">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
|
|
<!-- Styles -->
|
|
<link rel="stylesheet" href="//cdn.plyr.io/1.0.31/plyr.css">
|
|
|
|
<!-- Docs styles -->
|
|
<link rel="stylesheet" href="//cdn.plyr.io/1.0.31/docs.css">
|
|
</head>
|
|
<body>
|
|
<header>
|
|
<h1>Plyr</h1>
|
|
<p>A simple HTML5 media player with custom controls and WebVTT captions.</p>
|
|
<a href="https://github.com/selz/plyr" target="_blank" class="btn">Download on GitHub</a>
|
|
</header>
|
|
|
|
<main>
|
|
<section class="example-video">
|
|
<div class="player">
|
|
<video poster="//cdn.selz.com/plyr/1.0/poster.jpg" controls crossorigin>
|
|
<!-- Video files -->
|
|
<source src="//cdn.selz.com/plyr/1.0/movie.mp4" type="video/mp4">
|
|
<source src="//cdn.selz.com/plyr/1.0/movie.webm" type="video/webm">
|
|
|
|
<!-- Text track file -->
|
|
<track kind="captions" label="English" srclang="en" src="//cdn.selz.com/plyr/1.0/en.vtt" default>
|
|
|
|
<!-- Fallback for browsers that don't support the <video> element -->
|
|
<div>
|
|
<a href="//cdn.selz.com/plyr/1.0/movie.mp4">Download</a>
|
|
</div>
|
|
</video>
|
|
</div>
|
|
<small>Big Buck Bunny. More info can be found at <a href="https://peach.blender.org" target="_blank">peach.blender.org</a>.</small>
|
|
</section>
|
|
|
|
<section class="example-audio">
|
|
<div class="player">
|
|
<audio controls>
|
|
<!-- Audio files -->
|
|
<source src="//cdn.selz.com/plyr/1.0/logistics-96-sample.mp3" type="audio/mp3">
|
|
<source src="//cdn.selz.com/plyr/1.0/logistics-96-sample.ogg" type="audio/ogg">
|
|
|
|
<!-- Fallback for browsers that don't support the <audio> element -->
|
|
<div>
|
|
<a href="//cdn.selz.com/plyr/1.0/logistics-96-sample.mp3">Download</a>
|
|
</div>
|
|
</audio>
|
|
</div>
|
|
<small>"96" by Logistics, which can be purchased from <a href="https://www.hospitalrecords.com/shop/artist/logistics" target="_blank">Hospital Records</a>.</small>
|
|
</section>
|
|
</main>
|
|
|
|
<footer>
|
|
<p>Used by …</p>
|
|
<a href="https://selz.com" target="_blank" class="logo">
|
|
<img src="https://d33i624pw6jj68.cloudfront.net/static/img/logos/selz.svg" alt="Selz">
|
|
</a>
|
|
</footer>
|
|
|
|
<!-- Load SVG defs -->
|
|
<!-- You should bundle all SVG/Icons into one file using a build tool such as gulp and svg store -->
|
|
<script>
|
|
(function(d, u){
|
|
var a = new XMLHttpRequest(),
|
|
b = d.body;
|
|
|
|
// Check for CORS support
|
|
// If you're loading from same domain, you can remove the if statement
|
|
if("withCredentials" in a) {
|
|
a.open("GET", u, true);
|
|
a.send();
|
|
a.onload = function(){
|
|
var c = d.createElement("div");
|
|
c.style.display="none";
|
|
c.innerHTML = a.responseText;
|
|
b.insertBefore(c, b.childNodes[0]);
|
|
}
|
|
}
|
|
})(document, "https://cdn.plyr.io/1.0.31/sprite.svg");
|
|
</script>
|
|
|
|
<!-- Plyr core script -->
|
|
<script src="//cdn.plyr.io/1.0.31/plyr.js"></script>
|
|
|
|
<!-- Docs script -->
|
|
<script src="//cdn.plyr.io/1.0.31/docs.js"></script>
|
|
</body>
|
|
</html> |