Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
One comment per discussion
GeekyNow
New
I wanted to allow my forum users to post only one comment per discussion. How to make it possible?
0
Comments
write a plugin that checks the id's of all users in that specific discussion. if there is a match prohibit the posting.
or beforesavecomment trigger.
check the comment table for the specific discussionid and userid of poster if it returns null allow the post. (if the person is not editing the comment).
I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.
Adding to what peregrine said:
Take a look at the InThisDiscussionModule
https://github.com/vanilla/vanilla/blob/master/plugins/VanillaInThisDiscussion/class.inthisdiscussionmodule.php
It should give you an idea how to query for users of a discussion.
My themes: pure | minusbaseline - My plugins: CSSedit | HTMLedit | InfiniteScroll | BirthdayModule | [all] - PM me about customizations
VanillaSkins.com - Plugins, Themes and Graphics for Vanillaforums OS