changeset 19:2303c381151b

add webcomic-style interface by k0s
author egj@socialplanning.org
date Mon, 04 Jan 2010 05:42:57 +0000
parents c49d93044981
children c2d59b93aa43
files montage/templates/sequence.html
diffstat 1 files changed, 6 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/montage/templates/sequence.html	Mon Jan 04 04:52:16 2010 +0000
+++ b/montage/templates/sequence.html	Mon Jan 04 05:42:57 2010 +0000
@@ -11,7 +11,7 @@
   <body>
     <xi:include py:if="include" href="${include}"/>
 
-    <center py:if="files" py:with="index = int(request.GET.get('index', 0)">
+    <center py:if="files" py:with="index = int(request.GET.get('index', 0))">
       <div py:with="image = files[index]" class="image">
         <a href="${image['link']}">
           <img src="${image['path']}" width="${width or None}" height="${height or None}"/>
@@ -20,10 +20,13 @@
         ${image.get('title', image['description'])}
       </div>
       <py:if test="index &gt; 0">
-	<a href="?index=${index - 1}" py:with="image=${files[index - 1]}">${image.get('title, image.get('description', '<<'))}</a>
+	<a href="?index=${index - 1}"
+	   py:with="image=files[index - 1]">
+	  ${image.get("title", image.get("description", "&raquo;&raquo;"))}
+	</a>
       </py:if>
       <py:if test="index &lt; len(files)">
-	<a href="?index=${index + 1}" py:with="image=${files[index +1 1]}">${image.get('title, image.get('description', '>>'))}</a>
+	<a href="?index=${index + 1}" py:with="image=files[index + 1]">${image.get('title', image.get('description', '&laquo;&laquo;'))}</a>
       </py:if>
     </center>
   </body>