M Matthew2D Well-known member Jul 7, 2012 #1 Hello. I am having trouble making permissions for an addon. I already made the permission but I don't know what code to add to the addon template. Thanks in advance.
Hello. I am having trouble making permissions for an addon. I already made the permission but I don't know what code to add to the addon template. Thanks in advance.
Jake Bunce Well-known member Jul 8, 2012 #2 For example: Rich (BB code): $visitor = XenForo_Visitor::getInstance(); $hasPerm = XenForo_Permission::hasPermission($visitor['permissions'], 'general', 'cleanSpam') if ($hasPerm) { // DO STUFF }
For example: Rich (BB code): $visitor = XenForo_Visitor::getInstance(); $hasPerm = XenForo_Permission::hasPermission($visitor['permissions'], 'general', 'cleanSpam') if ($hasPerm) { // DO STUFF }