Merge pull request #661 from anaggh/master
Fix pagination in blogx and alternative
This commit is contained in:
commit
321225c6b7
|
@ -169,7 +169,7 @@ class Theme {
|
|||
public static function jquery($cdn=false)
|
||||
{
|
||||
if ($cdn) {
|
||||
return '<script src="https://code.jquery.com/jquery-3.2.1.min.js" integrity="sha256-hwg4gsxgFZhOsEEamdOYGBf13FyQuiTwlAQgxVSNgt4=" crossorigin="anonymous"></script>';
|
||||
return '<script src="https://code.jquery.com/jquery-3.3.1.min.js" integrity="sha384-tsQFqpEReu7ZLhBV2VZlAu7zcOV+rXbYlF2cqB8txI/8aZajjp4Bqd+V6D5IgvKT" crossorigin="anonymous"></script>';
|
||||
}
|
||||
return '<script src="'.DOMAIN_CORE_JS.'jquery.min.js'.'"></script>'.PHP_EOL;
|
||||
}
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
|
||||
<!-- Javascript -->
|
||||
<?php
|
||||
echo Theme::js('js/jquery.min.js');
|
||||
echo Theme::jquery();
|
||||
echo Theme::js('js/bootstrap.min.js');
|
||||
?>
|
||||
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -45,28 +45,26 @@
|
|||
|
||||
<!-- Pagination -->
|
||||
<?php if (Paginator::amountOfPages()>1): ?>
|
||||
<div class="paginator">
|
||||
<nav aria-label="Page navigation">
|
||||
<ul class="pagination justify-content-center">
|
||||
<nav class="paginator" aria-label="Page navigation">
|
||||
<ul class="pagination flex-wrap justify-content-center">
|
||||
|
||||
<!-- Previuos button -->
|
||||
<li class="page-item <?php if (Paginator::showNext()); echo 'disabled' ?>">
|
||||
<a class="page-link" href="<?php echo Paginator::prevPageUrl(); ?>" tabindex="-1">Previous</a>
|
||||
</li>
|
||||
<!-- Previous button -->
|
||||
<li class="page-item <?php if (!Paginator::showPrev()) echo 'disabled' ?>">
|
||||
<a class="page-link" href="<?php echo Paginator::prevPageUrl() ?>" tabindex="-1">Previous</a>
|
||||
</li>
|
||||
|
||||
<!-- List of pages -->
|
||||
<?php for ($i = 1; $i <= Paginator::amountOfPages(); $i++): ?>
|
||||
<li class="page-item <?php if ($i==Paginator::currentPage()); echo 'active' ?>">
|
||||
<a class="page-link" href="<?php echo Paginator::numberUrl($i); ?>"><?php echo $i ?></a>
|
||||
</li>
|
||||
<?php endfor ?>
|
||||
<!-- List of pages -->
|
||||
<?php for ($i = 1; $i <= Paginator::amountOfPages(); $i++): ?>
|
||||
<li class="page-item <?php if ($i==Paginator::currentPage()) echo 'active' ?>">
|
||||
<a class="page-link" href="<?php echo Paginator::numberUrl($i) ?>"><?php echo $i ?></a>
|
||||
</li>
|
||||
<?php endfor ?>
|
||||
|
||||
<!-- Next button -->
|
||||
<li class="page-item <?php if (Paginator::showPrev()); echo 'disabled' ?>">
|
||||
<a class="page-link" href="<?php echo Paginator::nextPageUrl(); ?>">Next</a>
|
||||
</li>
|
||||
<!-- Next button -->
|
||||
<li class="page-item <?php if (!Paginator::showNext()) echo 'disabled' ?>">
|
||||
<a class="page-link" href="<?php echo Paginator::nextPageUrl() ?>">Next</a>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
||||
</ul>
|
||||
</nav>
|
||||
<?php endif ?>
|
||||
|
|
|
@ -46,7 +46,7 @@
|
|||
|
||||
<!-- Javascript -->
|
||||
<?php
|
||||
echo Theme::js('js/jquery.min.js');
|
||||
echo Theme::jquery();
|
||||
echo Theme::js('js/bootstrap.min.js');
|
||||
?>
|
||||
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -35,10 +35,10 @@
|
|||
<!-- Pagination -->
|
||||
<?php if (Paginator::amountOfPages()>1): ?>
|
||||
<nav class="my-4" aria-label="Page navigation">
|
||||
<ul class="pagination">
|
||||
<ul class="pagination flex-wrap">
|
||||
|
||||
<!-- Previuos button -->
|
||||
<li class="page-item <?php if (Paginator::showNext()) echo 'disabled' ?>">
|
||||
<!-- Previous button -->
|
||||
<li class="page-item <?php if (!Paginator::showPrev()) echo 'disabled' ?>">
|
||||
<a class="page-link" href="<?php echo Paginator::prevPageUrl() ?>" tabindex="-1">Previous</a>
|
||||
</li>
|
||||
|
||||
|
@ -50,7 +50,7 @@
|
|||
<?php endfor ?>
|
||||
|
||||
<!-- Next button -->
|
||||
<li class="page-item <?php if (Paginator::showPrev()) echo 'disabled' ?>">
|
||||
<li class="page-item <?php if (!Paginator::showNext()) echo 'disabled' ?>">
|
||||
<a class="page-link" href="<?php echo Paginator::nextPageUrl() ?>">Next</a>
|
||||
</li>
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@
|
|||
|
||||
<!-- Javascript -->
|
||||
<?php
|
||||
echo Theme::js('js/jquery.min.js');
|
||||
echo Theme::jquery();
|
||||
echo Theme::js('js/bootstrap.min.js');
|
||||
echo Theme::js('js/highlight.min.js');
|
||||
?>
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue