use jplayer
[radio.git] / html / index.html
index fdfc42a..8f7a641 100644 (file)
@@ -6,16 +6,97 @@
 
         <link rel="stylesheet" type="text/css" media="all" href="style.css" />
 
+        <script type="text/javascript"
+                language="javascript"
+                src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js">
+        </script>
+
+        <link type="text/css" href="skin/blue.monday/css/jplayer.blue.monday.min.css" rel="stylesheet" />
+        <script type="text/javascript" src="js/jquery.jplayer.min.js"></script>
+
+        <script>
+
+$(document).ready(function(){
+          var stream = {
+               title: "Proxy Radio",
+               mp3: "http://radio.wpitchoune.net:8080/mp3"
+       },
+       ready = false;
+
+       $("#jquery_jplayer_1").jPlayer({
+               ready: function (event) {
+                       ready = true;
+                       $(this).jPlayer("setMedia", stream);
+               },
+               pause: function() {
+                       $(this).jPlayer("clearMedia");
+               },
+               error: function(event) {
+                       if(ready && event.jPlayer.error.type === $.jPlayer.error.URL_NOT_SET) {
+                               // Setup the media stream again and play it.
+                               $(this).jPlayer("setMedia", stream).jPlayer("play");
+                       }
+               },
+               swfPath: "../dist/jplayer",
+               supplied: "mp3",
+               preload: "none",
+               wmode: "window",
+               useStateClassSkin: true,
+               autoBlur: false,
+               keyEnabled: true
+       });
+});
+        </script>
+
         <title>Proxy Radio</title>
 </head>
 
 <body>
-        <section>
-                <h1>Proxy Radio</h1>
+        <nav>
+                <ul>
+                        <li class="selected">Proxy Radio</li>
+                        <li><a href="last_songs.html">Played songs</a></li>
+                        <li><a href="songs.html">All songs</a></li>
+                </ul>
+        </nav>
 
-                <audio controls>
+        <section>
+<div id="jquery_jplayer_1" class="jp-jplayer"></div>
+<div id="jp_container_1" class="jp-audio" role="application" aria-label="media player">
+        <div class="jp-type-single">
+                <div class="jp-gui jp-interface">
+                        <div class="jp-volume-controls">
+                                <button class="jp-mute" role="button" tabindex="0">mute</button>
+                                <button class="jp-volume-max" role="button" tabindex="0">max volume</button>
+                                <div class="jp-volume-bar">
+                                        <div class="jp-volume-bar-value"></div>
+                                </div>
+                        </div>
+                        <div class="jp-controls-holder">
+                                <div class="jp-controls">
+                                        <button class="jp-play" role="button" tabindex="0">play</button>
+                                        <button class="jp-stop" role="button" tabindex="0">stop</button>
+                                </div>
+                                <div class="jp-progress">
+                                        <div class="jp-seek-bar">
+                                                <div class="jp-play-bar"></div>
+                                        </div>
+                                </div>
+                                <div class="jp-current-time" role="timer" aria-label="time">&nbsp;</div>                                
+                        </div>
+                </div>
+                <div class="jp-details">
+                        <div class="jp-title" aria-label="title">&nbsp;</div>
+                </div>
+                <div class="jp-no-solution">
+                        <span>Update Required</span>
+                        To play the media you will need to either update your browser to a recent version or update your <a href="http://get.adobe.com/flashplayer/" target="_blank">Flash plugin</a>.
+                </div>
+        </div>
+</div>
+                <!--<audio controls>
                         <source src="http://radio.wpitchoune.net:8080/mp3">
-                </audio>
+                </audio>-->
 
                 <p>If the above player does not work you can play directly the
                         <a href="http://radio.wpitchoune.net:8080/mp3">stream</a>.</p>
                         <a href="http://radio.wpitchoune.net:8080">the icecast
                                    page</a>.</p>
 
+                <p>See the list of <a href="last_songs.html">recently played songs</a>.</p>
+
                 <p>All songs have been downloaded from the <a href="http://freemusicarchive.org/">Free Music Archive</a> and as far as I know can be shared on this stream. Feel free to send me an email to <a href="mailto:proxyradio@wpitchoune.net">proxyradio@wpitchoune.net</a>                        if you have a concern about a song. Read the list of
                         <a href="songs.html">songs</a> with credits and licensing information. No changes have been made to the songs.
                 </p>
         </section>
 
         <footer>
-                <p>(c) Proxy Radio</p>
+                <p><address><a href="mailto:proxyradio@wpitchoune.net">Proxy Radio</a></address</p>
         </footer>
 </body>