Sorry to bother.....
got it after all.
var $paginate = array(
'limit' =>10,
'contain' => array(...
.....
.....
)))
);
Dave
_____
From: Dave Maharaj :: WidePixels.com [mailto:[email protected]]
Sent: June-19-09 9:55 AM
To: [email protected]
Subject: Pagiate contain
I have a search function built based off the hoc_joins tutorial by Nate
inthe Bakery.
Now the search runs fine searching thru 2 associated HABTM tables matching
up items the user selects.
My last line is :
$data = $this->paginate('Post', array('Post.id' => $posts));
but that is pulling model data unrelated to the search (its running a query
everywhere a Post.id matches any table found inthe db, hasOne, hasMany,
HABTM)
How can I cut out models from being queried with contain in pagination?
Tried a few ways but nothing....
Dave
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" 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
-~----------~----~----~----~------~----~------~--~---