http://cake.insertdesignhere.com/posts/view/16

On Jan 30, 8:20 am, Ámon Tamás <[EMAIL PROTECTED]> wrote:
> Hello,
>
> Where can I find any manual or example about the paginator helper from 1.2?
>
> Now I usin the Pear::Pager for paginating, and I like to change it to
> the embedded one.
>
> Now my lines look like this:
>
> --
> function lista($cid = null) {
>    $lparams = array(
>      'perPage'     => 5,
>      'totalItems'  => $this->Classadd->findCount("Category.id = {$cid}
> || Category.parent_id = {$cid}"),
>      'currentPage' => ((isset($_GET['page']))?$_GET['page']:1),
>      'fileName'    => '/classadds/lista/'.$cid.'&page=%d',
>    );
>    $this->Pager->init($lparams);
>     $this->Classadd->Category->recursive = 2;
>      if ($cid) {
>        $this->set('classadds', $this->Classadd->findAll("Category.id =
> {$cid} || Category.parent_id = {$cid}", null, "Classadd.created DESC",
> $this->Pager->params['perPage'], $this->Pager->params['currentPage']));
>      }else{
>        $this->set('classadds', $this->Classadd->findAll());
>      }
>    }
> --
>
> And I like to change it to the new one.
> Thanks for help.
>
> --
> Ámon Tamáshttp://linkfelho.amon.hu


--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to