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.
How to add a textbox into the Comment Form?
luasoft
New
To add a textbox into the Discussion form, i used the hook:
public function PostController_AfterDiscussionFormOptions_Handler($Sender) { echo '<input type="text" name="Options" >'; }
and now, i want to add a text into the Comment Form,
is there the PostController_AfterCommentFormOptions_Handler($Sender) {} hook or a similar hook?
thanks!
0
Comments
Yes, DiscussionController_AfterBodyField_Handler.
My themes: pure | minusbaseline - My plugins: CSSedit | HTMLedit | InfiniteScroll | BirthdayModule | [all] - PM me about customizations
VanillaSkins.com - Plugins, Themes and Graphics for Vanillaforums OS
Try the eventi plugin if you are looking for hooks. It will help you find the hooks you are looking for
Like I said use the form builder, rather then hard coding the input.
It is also worth looking at the context of the hook, in this case a view. As that will tell you what is appropriate.
That is why I recommend grep, if you can't find something.
Say for instance you have options, and the view loop through "options", and the hook has the "options" argument passed by reference. In that case and
echo
is wrong, becuase the loop takes care for that, it would be out of place, instead you would add to the options collection.So check to see how exactly you would output when using any form/views hooks.
grep is your friend.
great, thanks
thanks, installed but it's not working on version 2.1.8p2
As far as I know the icons do not appear any more (since 2.1?), but that would be the only difference. It should still add markup to each page where there is an event fired and give you additional info there.