Skip to Content.
Sympa Menu

comanage-dev - [comanage-dev] getting model instance outside of controller

Subject: COmanage Developers List

List archive

[comanage-dev] getting model instance outside of controller


Chronological Thread 
  • From: Scott Koranda <>
  • To: comanage-dev <>
  • Subject: [comanage-dev] getting model instance outside of controller
  • Date: Fri, 24 Feb 2012 13:59:06 -0600
  • Authentication-results: mr.google.com; spf=pass (google.com: domain of designates 10.50.189.134 as permitted sender) ; dkim=pass

Hi,

I think you can do this to get an instance of a model outside
of a controller:

$cmpEnrollConfig = ClassRegistry::init('CmpEnrollmentConfiguration');

See

http://api.cakephp.org/class/class-registry#method-ClassRegistryinit

and

http://groups.google.com/group/cake-php/msg/794c451038c0c798k

Scott



Archive powered by MHonArc 2.6.16.

Top of Page