Laravel Pagination Example Tutorial
Frst command on Colltroller
public function index()
{
$user = DB::table('user')->paginate(15);
return view('user.index', ['user' => $user]);
}
Than Blade File Of View Given
<div class="container">
@foreach ($user as $user)
{{ $user->name }}
@endforeach
</div>
{{ $users->links() }}
Post a Comment