of http://book.cakephp.org/view/166/Pagination-in-Views
Maybe you can tweak it.
Regards
On 1 nov, 01:15, "Novice Programmer" <novice.prog...@gmail.com> wrote:
> Any ideas on what this can be?
>
> Thanks.
>
> On Sat, Nov 1, 2008 at 5:28 AM, Novice Programmer
> <novice.prog...@gmail.com>wrote:
>
>
>
> > Hello guys,
>
> > I have defined following route in routes.php:
> > Router::connect('/users/:uid/friends/*', array('controller' => 'users',
> > 'action' => 'friends'),
> > array('pass'=>array('uid')));
>
> > when i try to use paginator to build pagination links, the links to pages
> > look like the default cake php route:
> > they look as /users/friends/<uid>/page:1 where as using the above route, i
> > expect them to be: /users/<uid>/friends/page:1.
>
> > I am confused whether this a bug or feature? My pagination code for
> > building the links:
>
> > <?=$paginator->last('<img src="/img/last.gif" border="0" width="18"
> > height="18" />',
> > array('escape'=>false));?>
>
> > <?= $paginator->numbers(); ?>
>
> > My paginate setup:
>
> > $this->paginate = array('limit'=>1,
> > 'page'=>1,
> > 'order'=>'UsersFriend.created DESC',
> > 'contain'=>array('User', 'Profile'));
>
> > $data = $this->paginate('UsersFriend',
> > array('UsersFriend.user_id'=>$user['User']['id']));
>
> > Please help.
>
> > --
> > Thanks & Regards,
> > Novice.
>
> --
> Thanks & Regards,
> Novice.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---
No comments:
Post a Comment