Forum: Ruby on Rails Implementing commenting system using acts_as_nested_set

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Love AJAX (Guest)
on 2007-07-24 14:43
(Received via mailing list)

I have been trying to implemented a commenting system for my Job
model. I pretty much got my model to work using (better_)
acts_as_nested_set. But I am finding it difficult to display the
comments in views. How would I recurse the comment tree and display
the comment details for each child. I was thinking of something like

@comments = job.comments

for comment in @comments
  <p> display comment details here </p>
  <% --recurse-- unless comment.children.empty? %>

Any help?

Thanks much.
This topic is locked and can not be replied to.