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 apply condition to a function in tagging plugin?

rornvirornvi New
edited March 2012 in Vanilla 2.0 - 2.8

I want to allow addition tags on new discussion only for the moderators/admins. I peeped into class.tagging.plugin.php and commented out the code of public function PostController_BeforeFormButtons_Handler($Sender), which removes the input form for everybody.

I tried applying a condition if ( $Session->CheckPermission('Garden.Settings.Manage') ) but got php errors.


  • Options
    mcu_hqmcu_hq yippie ki-yay ✭✭✭
    edited March 2012

    Would help to post your errors, but I'm going to assume that you forgot to add this above your conditional statement:

    $Session = Gdn::Session();

    You are on the right track though. It should be a fairly easy modification.

Sign In or Register to comment.