var $uses = BAD!

If your models are related to each other User hasMany Post /  Post belongsTo
User

Then you can access each respective model by $this->User->Post // in Users
Controller
Or
$this->Post->User in Posts controller.

Not sure if it could get much easier

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf
Of cake-learner
Sent: Thursday, February 10, 2011 4:16 PM
To: CakePHP
Subject: should be able to access model easier

Why not we can't access models by
$this -> Controller -> ModelName( I meant all models defined in
$uses )
or
$this -> Controller -> Uses -> ModelName?


-- 
Our newest site for the community: CakePHP Video Tutorials
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help
others with their CakePHP related questions.


To unsubscribe from this group, send email to
[email protected] For more options, visit this group at
http://groups.google.com/group/cake-php

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
[email protected] For more options, visit this group at 
http://groups.google.com/group/cake-php

Reply via email to