22 lines
883 B
PHTML
22 lines
883 B
PHTML
<?php if ($paginator->getNumPages() > 1): ?>
|
|
<ul class="pagination">
|
|
<?php if ($paginator->getPrevUrl()): ?>
|
|
<li><a href="<?php echo $paginator->getPrevUrl(); ?>">« Previous</a></li>
|
|
<?php endif; ?>
|
|
|
|
<?php foreach ($paginator->getPages() as $page): ?>
|
|
<?php if ($page['url']): ?>
|
|
<li <?php echo $page['isCurrent'] ? 'class="active"' : ''; ?>>
|
|
<a href="<?php echo $page['url']; ?>"><?php echo $page['num']; ?></a>
|
|
</li>
|
|
<?php else: ?>
|
|
<li class="disabled"><span><?php echo $page['num']; ?></span></li>
|
|
<?php endif; ?>
|
|
<?php endforeach; ?>
|
|
|
|
<?php if ($paginator->getNextUrl()): ?>
|
|
<li><a href="<?php echo $paginator->getNextUrl(); ?>">Next »</a></li>
|
|
<?php endif; ?>
|
|
</ul>
|
|
<?php endif; ?>
|