Nov
23
How to create a digg and sabros.us style pagination with PHP
I think that this entry is obsolete. If you are looking for a pagination control, you can read this article which is eaiser to implement.
I made a few modifications to the sabros.us’s pagination script, inspired by the original created by strangerstudios.com, it needs a detail, turn it into a dynamic and re-usable function without so much roll.
Now the form to use it is super simple, we just call the function pagination() with the next parameters:
- Amount of pages
- Items by page
- Present page (or the one that is being seen)
- The page to which it will send the parameter of the following one (previous, first, last) page(?page=X)
- The amount of adjacent links to the present page



