How to make paging from the basics |
Maybe this will help you.
Pagination with CodeIgniter What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
read the codeigniter documentation,
in your db query you did not set offset. your can find examples here: https://www.codeigniter.com/userguide3/d...ilder.html
read the codeigniter documentation,
in your db query you did not set offset. your can find examples here: https://www.codeigniter.com/userguide3/d...ilder.html
I have a lot tables on my project and I found DataTable is very helpful. DataTable is very easy to config on how you want the pagination, global search, custom search
so on. There are couple of ways to get your data to view. I found the best way always to get your query to return as array then json_encode it then make ajax callback to build it Regards
Everything works, the only thing I can not fix is the url, in fact every page is shown as: mysite.com/per_page?=5
I could not do something like mysite.com/page/2 Il mio controller PHP Code: public function index() { |
Welcome Guest, Not a member yet? Register Sign In |