Re: [PHP] Algorithm: Limiting Large Numbers of Pages to 10 visible

2001-12-21 Thread Dimitris Kossikidis
Or you can use this simply class from Manuel Lemos's site. It works with Mysql only. http://phpclasses.upperdesign.com/browse.html/package/366 > Hi, > > I need an algorithm for paging. If I have 100 pages of results, I only > want to show > << Prev 1 2 3 4 5 6 7 8 9 10 Next >> > > Where I limit

[PHP] Algorithm: Limiting Large Numbers of Pages to 10 visible

2001-12-20 Thread Lara J. Fabans
Hi, I need an algorithm for paging. If I have 100 pages of results, I only want to show << Prev 1 2 3 4 5 6 7 8 9 10 Next >> Where I limit the number to 10 results of pages, but I cannot figure it out for the life of me. for ($i = $page; $i <= ($page+10); $i++) { if ($i != $page) {