Re: newbie. add inside a view

2007-03-19 Thread djiize

you can add a form (with Html helper for Cake 1.1 or Form helper for
Cake 1.2) in you page, just specify the correct action for adding a
comment (/comments/add ?)

and to display the list of comments, if you setup your models
associations (Comment belongsTo Post and Post hasMany Comment), when
you read a post ($post = $this->Post->read(null, $id); ), you have
comments in $post['Comment'] array
try a pr($post) to see Cake magic ;)

On 18 mar, 20:37, "sixlaneve" <[EMAIL PROTECTED]> wrote:
> sorry for this very newbie questions, but between bakery, here and
> google, still I haven't got an answer.
>
> let's take the blog tutorial in cakephp manual as example... when I
> look at one of the post, how can I add a field for adding comments,
> and how to display existing comments?
>
> Any examples? Tutorials?


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



newbie. add inside a view

2007-03-18 Thread sixlaneve

sorry for this very newbie questions, but between bakery, here and
google, still I haven't got an answer.

let's take the blog tutorial in cakephp manual as example... when I
look at one of the post, how can I add a field for adding comments,
and how to display existing comments?

Any examples? Tutorials?


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