[ansel] Patch to gallery.inc

Heath S. Hendrickson heath at outerspaceconsultants.com
Mon Jan 19 09:12:50 PST 2004


Here's a quick patch to add an indicator to the header of the gallery 
thumbnail view.  It shows

[ 0 - 15 of 150 images ]

right after the Refresh link.

heath



[root at space ansel]# cvs diff templates/view/gallery.inc
Index: templates/view/gallery.inc
===================================================================
RCS file: /usr/local/horde/cvs/ansel/templates/view/gallery.inc,v
retrieving revision 1.28
diff -r1.28 gallery.inc
22c22,34
<     <b><?php echo $title ?><?php if (!$print_view) { echo 
Horde::link(Horde::applicationUrl(Util::addParameter($viewurl, 'page', 
$page)), _("Refresh List")) . Horde::img('refresh.gif', _("Refresh 
List"), 'hspace="2"'); } ?></b>
---
 >     <b><?php echo $title ?><?php if (!$print_view) { echo 
Horde::link(Horde::applicationUrl(Util::addParameter($viewurl, 'page', 
$page)), _("Refresh List")) . Horde::img('refresh.gif', _("Refresh 
List"), 'hspace="3"'); } ?></b>
 >     <b><span class="header">[
 > <?php
 > $startimg = ($page) * $perpage;
 > $endimg = min($gallery->get('num-images'),$startimg + $perpage);
 > if($gallery->get('num-images') > 0) {
 >   echo $startimg . ' - ' . $endimg . ' of ' . 
$gallery->get('num-images');
 > } else {
 >   echo 0;
 > }
 > ?>
 > images]</span></b>
 >



More information about the ansel mailing list