HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Comment & registration plugin
mikerds
New
Hi there!
I found that sometime people want to answer a question (in case of a new forum) but they don't want to spend time on registration. So I want to build a form that combines registration and posting a comment, see below. When a user clicks "submit" button three things will happen:
1) it creates a new user
2) it creates a new post for this user
3) it creates a new session, so the user doesn't need to log in to keep posting.
Can somebody give me directions on how to start, which classes to modify?
Initially, I want to develop a draft version without any validation
PS: Hopefully it will be useful for people who start with a new empty forum.
Thank you!
0
Comments
Not sure how difficult that would be. Don't think about modifying classes. Changing Vanillas behavior happens by adding a plugin, not by changing existing files.
There is a plugin which seems to have similar intentions to what you are trying to achieve: https://open.vanillaforums.com/addon/commentbeforeregister-plugin
Thanks RJ! This is pretty much what I need.
It might be too much to ask...
Do you know if it is possible to redirect a user to Registration form instead of SignIn? As I am going to send a link to some posts to new users who are not registered yet.
One more question. What classes are responsible for rendering the discussion screen where "Leave a comment" form resides?
I quickly scanned the code, and it looks like these are:
applications/vanilla/views/post/discussion.php
applications/vanilla/views/post/comment.php
correct me if I am wrong.