Creating a comments section in sub-profiles

Back again with another need for some help… almost done with my project finally!

I am trying to setup a comments feature on my site. Users have their profiles and can create “Projects” which have their own profile.

Data Tables:

  • Users: Users
  • Projects: Builds

Here’s sort of a visual breakdown how this will need to go.

Normally I’d create a “Comments” Data Type but since each Project has their own individual comments I figure it most appropriate to add a “Comments” Line in the Projects data table.

Not sure where to go from here to get a simple comment feature working. Every tutorial I’ve found shows how to make a comments feature by using a “Comment” data type all in it’s own, but I need them to be individual per the Project’s page.

I have a simple multi-line input and a “Post” button. I figure the post button would send the value of the multi-line to the “comments” line on the DB. That part I can figure out just fine.

but how would I display replies and new comments in the DB to use it? I figure an RG nested inside an RG would be the way to go but I’ve hit a wall!

The design would look like:



So far I have managed to create a working commenting section.

One issue I am having is that the comments are all the same for each page, rather than being page-specific. How do I fix this?

Also, how would I go about showing the Username and Avatar of the user that posted a comment?

I’ve gotten the comment function to work, and it displays the comments properly along with the username of the commenter and their avatar.

The issue I am having is that this isn’t page-specific. If I go to another project page, it has the same comments as all the others.

This topic was automatically closed after 70 days. New replies are no longer allowed.