Re: Is it possible to check to see if model exists?

2009-07-10 Thread gerhardsletten
Mayby you have to use the try.. catch also http://mark-story.com/posts/view/simplifying-controller-logic-with-exceptions --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send em

Re: Is it possible to check to see if model exists?

2009-07-10 Thread Pixelastic
You can try App::import() (http://api.cakephp.org/class/app#method- Appimport) to check for a model availablity. You can also have a look at ClassRegistry::keys() and ClassRegistry::init() On Jul 10, 9:27 am, "Dr. Loboto" wrote: > What do you mean under "model exists", where do you check it and

Re: Is it possible to check to see if model exists?

2009-07-10 Thread Dr. Loboto
What do you mean under "model exists", where do you check it and for what purpose do you need it? Btw, method_exists won't work as loaded models in controllers and models are their properties, not methods. On Jul 10, 12:31 pm, eli_sier wrote: > I'd like to be able to check to see if a model exi

Is it possible to check to see if model exists?

2009-07-09 Thread eli_sier
I'd like to be able to check to see if a model exists. I've tried: method_exists($this, 'ModelName') but it does not seem to work. Any way of doing this? Cheers, Eli --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups