Right, I do know the difference between passedArgs & params; I was
getting mixed up because I'd been trying all sorts of combinations.
I'll ditch the component and try the built-in. I'm not exactly sure
why I wasn't using that in the first place.
thanks
On Mon, Mar 3, 2008 at 6:24 AM, AD7six <[EMAIL PROTECTED]> wrote:
>
>
>
> On Mar 3, 7:03 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
> wrote:
>
> > I'm using Andy's PaginationComponent in an admin action. The first
> > page loads fine but something's wrong with the route that's causing an
> > error. Here's the setup:
> >
> > ($page and $show would be set from $this->params or a default)
> >
> > $criteria = null;
> > $parameters = array('page' => $page);
> > $options = array(
> > 'url' => '/admin/events/',
> > 'sortByClass' => 'Event',
> > 'sortBy' => 'date_from',
> > 'direction' => 'DESC',
> > 'show' => $show,
> > 'maxPages' => 10,
> > 'paramStyle' => 'pretty',
> > 'paramSeparator' => ':'
> > );
> > list($order, $limit, $page) = $this->Pagination->init($criteria,
> > $parameters, $options);
> >
> > So, the links for the other pages are rendered like:
> >
> > /admin/events/page:3
>
> pretty params means /param/val/param2/val2 you want named params style
> but if you are using 1.2 you don't want to use that component at all -
> use the pagination that comes with cake.
>
> note that
> /admin/events/page:3
> is not the same to the router as
> /admin/events/index/page:3
>
> hth,
>
> AD
>
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---