Re: Pager 2.x
| From: | Lorenzo Alberton | Date: | Sun, 21 Mar 2004 17:29:48 +0000 |
| Subject: | Re: Pager 2.x | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-11419@lists.php.net to get a copy of this message | ||
Hi
On Sat, 20 Mar 2004 16:06:10 +0100, Daniel Kopp wrote:
> Hi!
> I am using pager 2.x and I really like it ... Very cool package
thanks
> But - one question: I use "Sliding" style -
> so I have something like:
>
> 1 << 40 41 *42* 43 44 >> 100
> where Page 42 is active. When I press >>
> I come to Page 43 with this:
> 1 << 41 42 *43* 44 45 >> 100
>
> This does not make too much sense to me
> as I could as well just click 43
right, but it behaves exactly the way it's meant to do.
The "jumping" mode is closer to what you're searching for.
"Sliding" means "smoothly move from one position to
the other, one small step at a time".
> Is there an easy way to get this upon clicking >>:
> 1 << 45 46 *47* 48 49 >> 100
> with Page 47 active? Or do I need to do that myself?
You could do that fairly easily extending Pager_Sliding
and overriding the "getNextPageID()" and getPrevPageID()"
methods.
HTH
Lorenzo