A classic example of pagination

Notice: This thread is very old.
akinyeleolubodun
Member | 4
+
0
-

Please can anyone help with pagination. The documentation is not explanatory on how to display the links on a template.

Last edited by akinyeleolubodun (2014-11-11 17:50)

cactux
Member | 12
+
0
-

I think the best way to do it is use persistent parameter in presenter (doc) and then pass the value to paginator like that:

$paginator->setPage($this->page);

Hope it helps.

Last edited by cactux (2014-11-11 18:16)

petr.pavel
Member | 535
+
0
-

You're right the documentation isn't complete. In fact, Nette doesn't actually contain any built-in visual part of the paginator. I never understood what's the point of having a hidden part without the visible one.

What most people do is that they download an add-on written by @DavidGrudl but I see now that the new add-ons website no longer hosts it. Don't ask me why, makes even less sense.

I guess you'll have to download someone else's implementation. A Google search gave me these:
https://github.com/…al-paginator
https://github.com/…al-paginator

David Kudera
Member | 455
+
0
-

Link to old visual paginator is at github. With some minor changes it still works great..

bazo
Member | 620
+
0
-

this one comes with a factory already try it https://packagist.org/…al-paginator