I am using a nginx-Server and Laravel 5.6 and wanted to use a Pagination for my table.
This is my nginx.conf:
location / {
try_files $uri $uri/ /index.php?$is_args$args;
This is my Controller:
public function getAllLocations()
{
$locations = Location::orderBy('name')->paginate(10);
return view('home', ['locations' => $locations, 'success' => false]);
}
My view:
<table class="table table-striped">
@foreach($locations as $location)
<tr id="">
<td></td>
</tr>
@endforeach
When I am clicking on the next Page the link is changing, but the same data is shown. Any ideas?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire