1 year ago

pagination and search

Posted 1 year ago by alirezaeshaqi

Hi, I am using laravel 5.4 and bootstrap 3 , I want use pagination and search . but I the pagination and search not working well. Here is my script code: $(document).ready(function() { $('#example').DataTable({ "searching": true, "paging": true, }); });

and HTML Code:

<h1> All Information</h1>   
<table id="example" class="table table-striped table-bordered" style="width:100%">
                <th>First Name</th>
                <th>Username(Student Id)</th>
                <th>Year Of Graduatuion</th>
                <th>Job Title</th>
                <th>Job Organization</th>
                <th>Job Province</th>
         @foreach($jobs as $job)

and Controller: public function index() { $jobs = Job::all(); return view('', compact('jobs')); }

Please sign in or create an account to participate in this conversation.