This was discussed in the laravel.io forums a while back, try to search it out. I forget the title that was attached. If I recall a solution was given., But basically a little trickery in the controller and keeping track of some vars will do.
Sep 18, 2015
5
Level 53
Multipagination in one view
Hey,
I have this requirement where I have to implement 2 different pagination links for 2 different tables in one page. For that to work, I need to change the query string name from page=N to something else like table_one_page=N and table_two_page=N but that does not work.
I mean, I can change the names by using
$this->user->paginate(10)->setPageName('users_page=N');
$this->something->paginate(10)->setPageName('something_page=N');
but the pages don't change.
I know that this was a bug in 5.0 and it was fixed in 5.1 but now when I am testing it on a new project, it doesn't change at all.
Anyone has any idea how I can fix this or has any idea for alternatives?
Please or to participate in this conversation.