I've been looking for some answers to my problems but after a couple
of hours of searching, I'll answer that.


a)   I would need to query differents models form a component. How to
do it?

b)   Looking at the manual it seems that each model has one controller
and one controller has one model. In addition, if I have some kind of
assosiation between models, for one controller it's possible to query
the other models associated. But if I don't have any association? How
can I query other models? (When I talk about models, maybe I should
talk about tables). I assume that it's possible to query directly by
$this->Mymodel->query(), but I would use Cake DB functions.

c)   Elements: this are pieces of code(view) that repeat in a part of
your site, so in order to not to repeat it. I've also seen that it's
not possible to query from elements directly to the database, but you
get information from the function set of your controller. If the query
and its bussiness logic is more than one line, you're also duplicating
code, so the answer is: can you type a function from a component that
sets the information to the view? So to set the information, just call
the component's funtion from a controller/action.


Thanks to all the help u can give me.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to