add a html 5 audio player to play the current item clicked
authornowmad@23.1.168.192.in-addr.arpa
Thu, 17 Dec 2015 12:14:31 +0100
changeset 65 5d5c30207e4c
parent 64 1931bbce5485
child 66 b7e750ed3ef5
add a html 5 audio player to play the current item clicked
cms/app-client/app/templates/player.hbs
--- a/cms/app-client/app/templates/player.hbs	Thu Dec 17 12:13:58 2015 +0100
+++ b/cms/app-client/app/templates/player.hbs	Thu Dec 17 12:14:31 2015 +0100
@@ -1,4 +1,14 @@
-<h2>This is the player</h2>
 <div class="corpus-app-content">
-  PLAYER
+  <audio id="audio-player" controls>
+    <source src="{{ currentItem.master }}" type="audio/ogg">
+    <source src="{{ currentItem.master }}" type="audio/mpeg">
+    <source src="{{ currentItem.master }}" type="audio/wav">
+    Your browser does not support the audio element.
+  </audio>
+  <p>
+    Title: {{ currentItem.title }}
+  </p>
+  <p>
+    Description: {{ currentItem.description }}
+  </p>
 </div>