updated paginator with support for hash
This commit is contained in:
parent
6a13dab2c9
commit
5c21b24ff4
@ -130,11 +130,13 @@ function getViewMode() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function updateHash() {
|
function updateHash() {
|
||||||
var hash, img = "";
|
var hash, img = "", val, i;
|
||||||
if (currentImg !== 0) {
|
if (currentImg !== 0) {
|
||||||
img = "img=" + currentImg;
|
img = "img=" + currentImg;
|
||||||
}
|
}
|
||||||
hash = "#" + img + getViewMode() + "&bgcolor=" + bgcolor;
|
hash = "#" + img + getViewMode() + "&bgcolor=" + bgcolor;
|
||||||
|
if($('#paginator')) { $('#paginator a').each(function () { val = $(this).attr("href"); i = val.indexOf("#"); if (i !== -1) { val = val.substr(0, i) } $(this).attr("href", val + hash); });
|
||||||
|
}
|
||||||
window.location.hash = hash;
|
window.location.hash = hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -96,8 +96,8 @@ endif;
|
|||||||
<? endif; ?>
|
<? endif; ?>
|
||||||
</div>
|
</div>
|
||||||
</td></tr></table>
|
</td></tr></table>
|
||||||
|
<div id="pearFlowPadd" class="imageflow" style="display: none;"></div>
|
||||||
|
<div id="pearImageFlow" class="imageflow" style="display: none;"> </div>
|
||||||
<?= $theme->album_bottom() ?>
|
<?= $theme->album_bottom() ?>
|
||||||
|
|
||||||
<?= $theme->paginator() ?>
|
<?= $theme->paginator() ?>
|
||||||
<div id="pearFlowPadd" class="imageflow" style="display: none;"></div>
|
|
||||||
<div id="pearImageFlow" class="imageflow" style="display: none;"> </div>
|
|
||||||
|
@ -30,12 +30,14 @@
|
|||||||
<li class="g-first">
|
<li class="g-first">
|
||||||
<? if ($page_type == "collection"): ?>
|
<? if ($page_type == "collection"): ?>
|
||||||
<? if (isset($first_page_url)): ?>
|
<? if (isset($first_page_url)): ?>
|
||||||
<a href="<?= $first_page_url ?>" class="buttonAction buttonFirst" title="<?= t("First") ?>"> </a>
|
<a href="<?= $first_page_url ?>" class="g-button ui-icon-left ui-state-default ui-corner-all" style="float: left;">
|
||||||
|
<span class="ui-icon ui-icon-seek-first"></span><?= t("First") ?></a>
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
|
|
||||||
<? if (isset($previous_page_url)): ?>
|
<? if (isset($previous_page_url)): ?>
|
||||||
<a href="<?= $previous_page_url ?>" class="buttonAction buttonPrev" title="<?= t("Previous") ?>"> </a>
|
<a href="<?= $previous_page_url ?>" class="g-button ui-icon-left ui-state-default ui-corner-all" style="float: left;">
|
||||||
|
<span class="ui-icon ui-icon-seek-prev"></span><?= t("Previous") ?></a>
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
|
|
||||||
</li>
|
</li>
|
||||||
@ -60,15 +62,15 @@
|
|||||||
|
|
||||||
<li class="g-text-right">
|
<li class="g-text-right">
|
||||||
<? if ($page_type == "collection"): ?>
|
<? if ($page_type == "collection"): ?>
|
||||||
<? if (isset($last_page_url)): ?>
|
|
||||||
<a href="<?= $last_page_url ?>" class="buttonAction buttonLast" title="<?= t("Last") ?>"> </a>
|
|
||||||
<? endif ?>
|
|
||||||
<? endif ?>
|
|
||||||
<? if (isset($next_page_url)): ?>
|
<? if (isset($next_page_url)): ?>
|
||||||
<a href="<?= $next_page_url ?>" class="buttonAction buttonNext" title="<?= t("Next") ?>"> </a>
|
<a href="<?= $next_page_url ?>" class="g-button ui-icon-right ui-state-default ui-corner-all">
|
||||||
|
<span class="ui-icon ui-icon-seek-next"></span><?= t("Next") ?></a>
|
||||||
|
<? endif ?>
|
||||||
|
<? if (isset($last_page_url)): ?>
|
||||||
|
<a href="<?= $last_page_url ?>" class="g-button ui-icon-right ui-state-default ui-corner-all">
|
||||||
|
<span class="ui-icon ui-icon-seek-end"></span><?= t("Last") ?></a>
|
||||||
|
<? endif ?>
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
|
|
||||||
|
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<? endif ?>
|
<? endif ?>
|
||||||
|
Reference in New Issue
Block a user