Forums / Setup & design / Adding comments to an object

"Please Note:
  • At the specific request of Ibexa we are changing this projects name to "Exponential" or "Exponential (CMS)" effective as of August, 11th 2025.
  • This project is not associated with the original eZ Publish software or its original developer, eZ Systems or Ibexa".

Adding comments to an object

Author Message

Christian Johansen

Friday 11 November 2005 6:51:50 am

Hi, I've looked at the tutorial for creating a guestbook: http://ez.no/products/ez_publish_cms/documentation/building_an_ez_publish_site/the_guestbook and allthough it comes close, it doesn't quite help me with what I want to do.

I want to create the possibility for anonymous users to post a comment to an article/arbitrary object. Can anyone point me in the direction of some tutorial/documentation of this?

I've used the built in comment type to add some comments to an article through the admin-interface but I want this functionality on the public site. I don't know which templates to override and such. Also - I don't know how I'm supposed to set the ordering to ascending without manually doing so for each article.

So far I have articles and they appear as containers, I thought this way they could contain articles. But I'm kinda lost, yet still I bet this is standard functionality? Any hints?

Łukasz Serwatka

Friday 18 November 2005 12:57:24 am

Hi Christian,

First you will need form which will pass some variables like NodeID of article, ClassID of comment to /content/action module. You can look on design/base/override/templates/full/article.tpl. There already is such code.

You will have to set right permission to Anonymous user, for content create and content edit.

template for comment edit, you can find in design/base/override/templates/edit/comment.tpl

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog