Saturday, May 29, 2010

Recursive some only some associations?

Hi all,

I have my models setup so: Person ---- Item ---- Images

I want to be able to display a list of People and their images. I can
do this through using recursive = 2 but it slows down the page a lot
as there are many other associations which are not required.

I've tried playing around with bindModel/unbindModel but without any
luck. I've also tried:
$this->Person->recursive = 1;
$this->Person->Item->recursive = 1;
Which I thought might work, but doesn't.

I would really appreciate any help or advice on this!

Cheers,
Antony

Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

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: