In general, read up about MVC as anselm said earlier
http://en.wikipedia.org/wiki/Model-view-controller is one site, but
there are a whole slew of other sites which provide descriptions which
should give you an overall view of what Cake is trying to achieve.

Hopefully, I have covered all your questions above.

1. Is there a formal thing called a "page template" and this is
meant to invoke its known properties?  Also, is "action" a defined
formal term for something?

A page template is a layout. It is the framework into which all your
content goes. You have a default layout, and each action may instead
define that it uses a different layout.

An action is a function in a controller class which basically becomes
the second item in a URL -
http://www.sitename.com/myControllerName/actionName/param1/param2/...
-where param1 and 2 etc are optional, and if you do not have an action,
it calls the index function in your controller.

2. What does "PostsController::add()" represent?

It represents a coll to the add funciton in the PostsController class
when you visit URL www.sitename.com/posts/add

3. What do you do with these files (view files)?

You define what the output to the browser is for the particular action.


4. Is that supposed to mean something, the "view template file"?
Is that the verb "to view the template file"?  Then we have
something called a template file and there s a file that when executed
displays it?  Where is this explained?

The template file is a file in the view directory. Any of the files
endin thtml are template files and they define in mixed HTML/PHP what
output is being provided to the browser.


5. How do you do that and why (you can use the data from the corresponding 
Model. This data is passed as an array called $data. )?

The Model class is your interface to the database table named after the
model. Any data in that table is available via the data array.

6. What does "using set" mean?

In your controller, you can use the function $this->set to allow you to
make data available to your view. The view can see no other data.

7. What are HTML helpers?

These are functions which are designed to make your job of editing the
thtml files and outputting HTML easier.

8. How can I see a list of all of these functions with explanations?

Look in api.cakephp.org The source code is available and can be read.

9. What does "default layout" mean?

Answered above.

10. Why do we create a layout and where does t explain how to?

So you can define your page.

11. What kind of thing is $content_for_layout?  And why is
$title_for_layout optional?

$content_for_layout is a string containing all of your output data. It
is where what you have defined in your view thtml file goes in your
layout.

$title_for_layout allows you to set a custom title for a page. It is
not required, but useful.

12. What is a controller variable?

A variable defined in a controller class.

13. What is the controller's $layout variable and setLayout()
function?

Allow you to override the default layout and provide a layout specific
for this controller or action.

14. What does it mean to give an element access to data, and to send it
as a named parameter in an array?

Elements do not see any data by default. You have to add an extra array
as the second parameter to render_element which contains a list of
parameters and their names.

15. What in general do you input into CakePHP?  How do you use it after
you do all the input to set it up?  What are the options that you can
use in order to run the application then?

Whatever your want to do.  Call the controller and action using the URL
of your page and it will run the code in that controller.

  Paul


--~--~---------~--~----~------------~-------~--~----~
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, 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