On Nov 27, 2:15 pm, Marcus Silva <marcuslighten...@gmail.com> wrote:
> Rafael just answered your question!!!
>
> On Nov 27, 1:59 pm, grigri <j...@hendersonwebdesign.com> wrote:
>
> > @Markus and Rafael
>
> > What's wrong with just going like this?
>
> > $this->set('data', $this->paginate('Model', $conditions));
>
> > Works fine for me
>
> > hth
> > grigri
>
> > On Nov 27, 12:41 pm, Marcus Silva <marcuslighten...@gmail.com> wrote:
>
> > > Hi Rafael,
>
> > > I think what you really need is to use paginate in the following way
> > > in conjunction with custom conditions:
>
> > > $conditions = array(); //Add your conditions here
> > > $this->paginate['Model']['conditions'] = $conditions;
>
> > > //now set the data
>
> > > $this->set( 'data', $this->paginate('Model') );
>
> > > Maybe that will work, used it before and worked for me...
>
> > > Let me know if it worked.
>
> > > Cheers
>
> > > Marcus
>
> > > On Nov 27, 12:32 pm, Rafael Bandeira aka rafaelbandeira3
>
> > > <rafaelbandei...@gmail.com> wrote:
> > > > > $this->set('filters',$this->Listing->Cuisine->find('all',array
> > > > > ('conditions'=>array('Cuisine.id'=>$searchby))), $this->paginate());
>
> > > > what is it supposed to do?
>
> > > > I think that what you really want to do is:
>
> > > > // in the controller
> > > > $this->set('filter', $this->paginate());
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---
Thursday, November 27, 2008
Re: HABTM pagination
My bad, I meant "Marcus" and "aron". Think my brain needs a defrag
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment