Maybe you can implement the function __get and that it load the model case has not been loaded yet.
[]'s Renan On Jan 28, 2008 11:25 AM, boyracerr <[EMAIL PROTECTED]> wrote: > > Sorry, but I've just been told about loadModel(), which does exactly > this. I did Google first, I swear. > > If anybody would like to comment on the advantages/drawbacks of > working like this though, I'd be interested to hear your thoughts. > > Benjamin > > On Jan 28, 12:15 pm, boyracerr <[EMAIL PROTECTED]> wrote: > > Hi to all, > > > > I'm currently getting stuck in to my first major CakePHP application. > > > > I'm writing the search functionality, one of the requirements for > > which is a unified search which can return different combinations of > > models. > > > > So, what I'd like to do is to be able to add models dynamically to the > > controller, depending on the incoming action. I wanted to just modify > > the 'uses' array in the relevant actions, but this doesn't work (I > > presume all that stuff is constructor handled). > > > > My questions are: > > > > 1. Is it possible to do this? > > 2. Is this a stupid idea? > > > > Thanks for any tips, > > Benjamin > > > > -- Renan Gonçalves - Software Engineer Cell Phone: +55 (11) 8633-6018 MSN: [EMAIL PROTECTED] Web Site: renangoncalves.com São Paulo - SP/Brazil --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
