fixed audiobook page
authorJan Szejko <jan.szejko@gmail.com>
Fri, 8 Apr 2016 09:53:15 +0000 (11:53 +0200)
committerJan Szejko <jan.szejko@gmail.com>
Fri, 8 Apr 2016 09:53:15 +0000 (11:53 +0200)
src/catalogue/templates/catalogue/player.html

index 8e8c9bb..91f0fa6 100755 (executable)
@@ -4,6 +4,7 @@
     {% load i18n pipeline %}
     {% load catalogue_tags %}
     {% load thumbnail %}
     {% load i18n pipeline %}
     {% load catalogue_tags %}
     {% load thumbnail %}
+    {% load piwik_tags %}
     <head>
         <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
         <meta name="description"
     <head>
         <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
         <meta name="description"
 </div>
 
 <div style="clear: both"></div>
 </div>
 
 <div style="clear: both"></div>
-
-<div class="jp-type-playlist">
-  <div id="jplayer" class="jp-jplayer"
-    data-supplied="{% if have_oggs %}oga,{% endif %}mp3"></div>
-  <div id="jp_container_1" class="jp-audio">
-    <div class="jp-type-single">
-      <div class="jp-gui jp-interface">
-        <ul class="jp-controls">
-          <li><a href="javascript:;" class="jp-play" tabindex="1">play</a></li>
-          <li><a href="javascript:;" class="jp-pause" tabindex="1">pause</a></li>
-          <li><a href="javascript:;" class="jp-stop" tabindex="1">stop</a></li>
-          <li><a href="javascript:;" class="jp-mute" tabindex="1" title="mute">mute</a></li>
-          <li><a href="javascript:;" class="jp-unmute" tabindex="1" title="unmute">unmute</a></li>
-          <li><a href="javascript:;" class="jp-volume-max" tabindex="1" title="max volume">max volume</a></li>
-        </ul>
-        <div class="jp-progress">
-          <div class="jp-seek-bar">
-            <div class="jp-play-bar"></div>
-          </div>
-        </div>
-        <div class="jp-volume-bar">
-          <div class="jp-volume-bar-value"></div>
-        </div>
-        <div class="jp-time-holder">
-          <div class="jp-current-time"></div>
-          <div class="jp-duration"></div>
-        </div>
-      </div>
-
-      <div class="jp-playlist">
-        <ul>
-
-        {% for i in audiobooks %}
-          <li>
-            <div class='play'>{{ i.mp3.name }}
-            <div class='extra-info'>
-              {% trans "Artist:" %}: <span class='artist'>{{ i.mp3.extra_info.artist_name }}</span>,
-              {% trans "director:" %}: <span class='director'>{{ i.mp3.extra_info.director_name }}</span>
-            </div>
-            </div>
-          </li>
-        {% endfor %}
-
-        </ul>
-      </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>
-</div>
-
+        {% include "catalogue/snippets/jplayer.html" %}
 
         {% if projects|length > 1 %}
             <p>{% trans "Audiobooks were prepared as a part of the projects:" %}</p>
 
         {% if projects|length > 1 %}
             <p>{% trans "Audiobooks were prepared as a part of the projects:" %}</p>
         <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
         {% javascript "player" %}
 
         <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
         {% javascript "player" %}
 
-        {{ piwik_tag|safe }}
+        {% tracking_code %}
     </body>
 </html>
     </body>
 </html>