Created
February 14, 2018 08:45
-
-
Save tokoiwesley/604476ad52e02bf194ae3acdeb6cacc9 to your computer and use it in GitHub Desktop.
Simple Semantic UI Pagination in Laravel
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Semantic UI | |
* @example $pages->links('vendor.pagination.simple-semantic-ui', ['paginator' => $pages]) | |
* @example @include('vendor.pagination.simple-semantic-ui', ['paginator' => $pages]) | |
**/ | |
?> | |
@if ($paginator->lastPage() > 1) | |
<div class="ui pagination menu"> | |
@for ($i = 1; $i <= $paginator->lastPage(); $i++) | |
<a href="{{ $paginator->url($i) }}" class="{{ ($paginator->currentPage() == $i) ? ' active' : '' }} item"> | |
{{ $i }} | |
</a> | |
@endfor | |
</div> | |
@endif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment