Hi!
I'm implementing a threaded commenting functionality to my site with only 2 levels of threading. For example:
User A: This is a message from User A!
I use relationships to relate sub comments to the main comment. The main comment is related to the owner of the profile page. The sub comments are related to the main comment.
The idea is that if user A deletes his comment, all sub comments are also deleted.
The problem I think is I don't know what to set the owner_guid and container_guid to for each elgg object. Setting the container_guid to to the parent comment or profile guid causes an issue if the poster doesnt own parent comment or profile. However, if I just set the container_guid to 0 I can't get cascading delete to work unless I use:
elgg_set_ignore_access(TRUE);
The line above seems like a hack...
What is the "proper" way to structure these objects? Thanks!
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by RaĆ¼l Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.