Esempio n. 1
0
				</a>
			<?php 
        }
        ?>
			</li>
			<?php 
    }
    ?>
		</ul>
	</div>
	<?php 
}
?>

	<?php 
if (getPrevPageURL() || getNextPageURL()) {
    printPageListWithNav('« ' . gettext('Prev'), gettext('Next') . ' »', false, 'true', 'page-nav', '', true, '5');
}
?>

	<?php 
if (function_exists('printGoogleMap')) {
    ?>
			<div class="gmap">
		<?php 
    setOption('gmap_width', 600, false);
    printGoogleMap();
    ?>
			</div>
	<?php 
}
Esempio n. 2
0
echo getGalleryTitle();
?>
</h2></div>

		<div id="img_header_bg">
			<div id="img_header">&nbsp;</div>
		</div>
	</div>

	<div id="navigation">
	   <ul>
<?php 
$totalPages = getTotalPages();
$currentPage = getCurrentPage();
if (hasPrevPage()) {
    $link = getPrevPageURL();
} else {
    $link = "#";
}
echo "<li><a href=\"{$link}\" title=\"Previous Page\">&laquo;</a></li>\n";
for ($i = 1; $i <= $totalPages; $i++) {
    echo $i == $currentPage ? '<li class="current">' : '<li>';
    if ($i < 10) {
        $page = '0' . $i;
    } else {
        $page = $i;
    }
    printLinkHTML(getPageNumURL($i), $page, "Page {$page}");
    echo "</li>\n";
}
if (hasNextPage()) {
/**
 * returns a page nav list.
 *
 * @param bool $_oneImagePage set to true if there is only one image page as, for instance, in flash themes
 * @param int $navlen Number of navigation links to show (0 for all pages). Works best if the number is odd.
 * @param bool $firstlast Add links to the first and last pages of you gallery
 * @param int $current the current page
 * @param int $total total number of pages
 *
 */
function getPageNavList($_oneImagePage, $navlen, $firstlast, $current, $total)
{
    $result = array();
    if (hasPrevPage()) {
        $result['prev'] = getPrevPageURL();
    } else {
        $result['prev'] = NULL;
    }
    if ($firstlast) {
        $result[1] = getPageNumURL(1, $total);
    }
    if ($navlen == 0) {
        $navlen = $total;
    }
    $extralinks = 2;
    if ($firstlast) {
        $extralinks = $extralinks + 2;
    }
    $len = floor(($navlen - $extralinks) / 2);
    $j = max(round($extralinks / 2), min($current - $len - (2 - round($extralinks / 2)), $total - $navlen + $extralinks - 1));
    $ilim = min($total, max($navlen - round($extralinks / 2), $current + floor($len)));
    $k1 = round(($j - 2) / 2) + 1;
    $k2 = $total - round(($total - $ilim) / 2);
    for ($i = $j; $i <= $ilim; $i++) {
        $result[$i] = getPageNumURL($i, $total);
    }
    if ($firstlast) {
        $result[$total] = getPageNumURL($total, $total);
    }
    if (hasNextPage()) {
        $result['next'] = getNextPageURL();
    } else {
        $result['next'] = NULL;
    }
    return $result;
}
Esempio n. 4
0
}
?>
					<li><h2><a href="<?php 
echo getGalleryIndexURL();
?>
"><?php 
echo getGalleryTitle();
?>
</a></h2></li>
				</ul>
				<ul class="move">
					<li><?php 
if (hasPrevPage()) {
    ?>
<a href="<?php 
    echo htmlspecialchars(getPrevPageURL());
    ?>
">Prev</a><?php 
} else {
    ?>
<span>Prev</span><?php 
}
?>
</li>
					<li><?php 
if (hasNextPage()) {
    ?>
<a href="<?php 
    echo htmlspecialchars(getNextPageURL());
    ?>
">Next</a><?php 
Esempio n. 5
0
					</a>
					
       			 </div>
			</div>
			
			<?php 
}
?>
		</div>
	<div class="clear"></div>
	<div id="tools">
		<?php 
if (hasPrevPage()) {
    ?>
		<a href="<?php 
    echo getPrevPageURL();
    ?>
"><span class="prev"></span></a>
		<?php 
} else {
    ?>
			<span class="prev-disabled"></span>
		<?php 
}
?>
	

		<?php 
if (hasNextPage()) {
    ?>
		<a href="<?php 
Esempio n. 6
0
if (!empty($params)) {
    if ($results != "0") {
        if ($firstImage + $lastImage != 0) {
            echo '<em class="count">';
            printf(gettext('Photos %1$u-%2$u of %3$u'), $firstImage, $lastImage, getNumImages());
            echo "</em>";
            if (function_exists('printSlideShowLink')) {
                printSlideShowLink(gettext('View Slideshow'));
            }
        }
        ?>
				<?php 
        if (hasPrevPage()) {
            ?>
				<a href="<?php 
            echo html_encode(getPrevPageURL());
            ?>
" accesskey="x">&laquo; <?php 
            echo gettext('prev page');
            ?>
</a>
				<?php 
        }
        if (hasNextPage()) {
            if (hasPrevPage()) {
                echo '&nbsp;';
            }
            ?>
				<a href="<?php 
            echo html_encode(getNextPageURL());
            ?>
Esempio n. 7
0
        ji_show_thumb();
    }
} else {
    while (next_album()) {
        ji_show_thumb();
    }
}
?>
		</ul>
	</div>

   <div id="fullplate-navigation">
   	<ul>
   <?php 
if (hasPrevPage()) {
    echo "\t\t" . '<li id="previous"><a href="' . getPrevPageURL() . '" title="Previous Image"><img src="' . $_zp_themeroot . '/images/arrow_left.png" width="16" height="16" alt="left ' . 'arrow" /></a></li>' . "\n";
} else {
    echo "\t\t" . '<li>&nbsp;</li>' . "\n";
}
if (in_context(ZP_IMAGE)) {
    echo "\t\t" . '<li><a href="' . getFullImageURL() . '" title="Full Size Image"><img src="' . $_zp_themeroot . '/images/arrow_out.png" width="16" height="16" alt="arrows ' . 'pointing out" /></a></li>' . "\n";
} else {
    echo "\t\t" . '<li>&nbsp;</li>' . "\n";
}
if (hasNextPage()) {
    echo "\t\t" . '<li id="next"><a href="' . getNextPageURL() . '" title="Next Image"><img src="' . $_zp_themeroot . '/images/arrow_right.png" width="16" height="16" alt="right ' . 'arrow" /></a></li>' . "\n";
} else {
    echo "\t\t" . '<li>&nbsp;</li>' . "\n";
}
?>
   	</ul>
/**
 * Returns the URL of the previous page.
 *
 * @param string $text The linktext that should be printed as a link
 * @param string $title The text the html-tag "title" should contain
 * @param string $class Insert here the CSS-class name you want to style the link with
 * @param string $id Insert here the CSS-ID name you want to style the link with
 */
function printPrevPageLink($text, $title = NULL, $class = NULL, $id = NULL)
{
    if (hasPrevPage()) {
        printLink(getPrevPageURL(), $text, $title, $class, $id);
    } else {
        echo "<span class=\"disabledlink\">{$text}</span>";
    }
}
Esempio n. 9
0
 static function printNavigation($prevtext, $nexttext, $oneImagePage = false, $navlen = 7, $firstlast = true)
 {
     $total = getTotalPages($oneImagePage);
     $current = getCurrentPage();
     if ($total < 2) {
         $class .= ' disabled_nav';
     }
     if ($navlen == 0) {
         $navlen = $total;
     }
     $extralinks = 2;
     if ($firstlast) {
         $extralinks += 2;
     }
     $len = floor(($navlen - $extralinks) / 2);
     $j = max(round($extralinks / 2), min($current - $len - (2 - round($extralinks / 2)), $total - $navlen + $extralinks - 1));
     $ilim = min($total, max($navlen - round($extralinks / 2), $current + floor($len)));
     $k1 = round(($j - 2) / 2) + 1;
     $k2 = $total - round(($total - $ilim) / 2);
     if ($firstlast) {
         echo '<div class="nav-cell ' . ($current == 1 ? 'current' : 'first') . '">';
         echo "<span class='valign'>";
         printLink(getPageURL(1, $total), 1, "Page 1");
         echo "</span></div>\n";
         if ($j > 2) {
             echo '<div class="nav-cell">';
             echo "<span class='valign'>";
             printLink(getPageURL($k1, $total), $j - 1 > 2 ? '...' : $k1, "Page {$k1}");
             echo "</span></div>\n";
         }
     }
     for ($i = $j; $i <= $ilim; $i++) {
         echo '<div class="nav-cell' . ($i == $current ? " current" : "") . '">';
         echo "<span class='valign'>";
         printLink(getPageURL($i, $total), $i, "Page {$i}" . ($i == $current ? ' ' . gettext("(Current Page)") : ""));
         echo "</span></div>\n";
     }
     if ($i < $total) {
         echo '<div class="nav-cell">';
         echo "<span class='valign'>";
         printLink(getPageURL($k2, $total), $total - $i > 1 ? '...' : $k2, "Page {$k2}");
         echo "</span></div>\n";
     }
     if ($firstlast && $i <= $total) {
         echo '<div class="nav-cell last">';
         echo "<span class='valign'>";
         printLink(getPageURL($total, $total), $total, "Page {$total}");
         echo "</span></div>\n";
     }
     $prevNextLinks = array();
     $prevNextLinks['prev'] = ThemeUtil::getLink(getPrevPageURL(), $prevtext) . "\n";
     $prevNextLinks['next'] = ThemeUtil::getLink(getNextPageURL(), $nexttext) . "\n";
     return $prevNextLinks;
 }