Hi,
I'm trying to make a very simple controller as I consider
transitioning my existing website to Cake. Early on I'm running into
this problem: My controller class is Securities and my model is
Security but when I try to produce the view I get this error:
Fatal error: Call to undefined method Security::read()
Now I've tried renaming all of my classes / files / db table to other
names and each time this has worked fine. I've tried Dogs (Dog) and
Buggies (Buggy) and both worked fine. Is there some special reason I
can't use Securities (Security) or is this a bug? (Note fails on both
1.2 and 1.19)
//controller
class SecuritiesController extends AppController {
var $name = 'Securities';
function view($id = null){
$this->Security->id = $id;
$this->set('security', $this->Security->read());
}
}
//model
class Security extends AppModel {
var $name = 'Security';
}
//view.ctp
<?php
print_r($security);
?>
Inflector seems fine:
echo Inflector::singularize('Securities') //prints Security
Thanks in advance for the help,
Dave
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" 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
-~----------~----~----~----~------~----~------~--~---