If its for models, use ClassRegistry::init(). If you are including files, use App::import().
If you are adding a file to the lookup, use App::uses(). https://github.com/cakephp/cakephp/blob/2.0/lib/Cake/Core/App.php#L549 On Oct 10, 9:20 am, CrotchFrog <crotchf...@gmail.com> wrote: > I'm still trying to figure out how to get function __ construct() to > work properly for me, it throws errors when used the way I > traditionally used it. I'm also still unsure whether I should be using > App::import() or App::uses(). I would tend to think App::import() but > like I said I'm a little fuzzy in this area. > > Thanks, > > - Ed > > On Oct 9, 6:09 am, CrotchFrog <crotchf...@gmail.com> wrote: > > > > > > > > > I'm a bit confused in the proper use of App::import() vs. App::uses() > > in migrating to 2.0. > > > I'm try to load the Facebook php sdk from the Vendor folder as I used > > to in 1.3. > > > In 1.3 what worked for me was : > > > App::import('Vendor', 'facebook) > > > function __construct(){ > > parent::__construct(); > > > $this->facebook = new Facebook(array( > > 'appId' => $this->__api_key, > > 'secret' => $this->__app_secret )); > > } > > > How should I be using the Constructor with App::uses()? > > I've been through the Migration Guide to 2.0 and can see there has > > been obvious changes but I suppose I don't have a clear enough > > understanding to work out what I should be doing differently here. > > > - Ed -- 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 cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php