find ('all') is too greedy, you need to be more specific if you don't want to run out of memory.
As stated above, use the Containable behavior. If you want only the results from your table (without related tables) and only for a few fields, a more explicit query like this should be better:
$results = $this->YourModel->find('all', array( 'contain' => false, 'fields' => array('YourModel.name', 'YourModel.url') );
You should also consider adding the html caching mechanism (cakePHP has a built-in or usable suggested by Matt Curry ).
Of course, this will be a cached version and will not fully correspond to your list. If you want more control, you can always save the result in the cake cache (using Cache :: write ), using your model's afterSave / afterDelete callbacks to update the cached value and recreate the cached xml file here.
pixelastic
source share