dkni, read the model, understand how MVC works. By default associated
models are loaded so you can make calls to the with
$this->ModelName->AssociatedModel.
But if you need to load up some others (really try and think of a way
not to do this a lot).
$uses = array('ModelName', 'otherModel');
The
You want two or more tables in one model?? that?s impossible, i think.
You should work with associations!
Maybe you should read the manual first..
http://manual.cakephp.org/chapter/models
> yup. but how do i have multiple tables in one Model?
>
>
> --~--~-~--~~~
yup. but how do i have multiple tables in one Model?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, s
> set member "$useTable" if your table name is different to your model name.
>
>
i meant: if the table name is not the plural of the model name.
of couse, in my example table name and model name are equal! ;o)
--~--~-~--~~~---~--~~
You received this message
hi.
set member "$useTable" if your table name is different to your model name.
class User extends AppModel
{
var $useTable = 'user';
...
}
is this what you want to know?
cheers.
> Can I have a table name that is singular and how should I implement it
> in model?
> Everytime when I r
Can I have a table name that is singular and how should I implement it
in model?
Everytime when I run it, it asked for a table name 'models'.
regards,
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups "Cake
PHP" grou