MyBB Central

Full Version: [Help] Editing RepFuck permissions.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi, I was wondering if it's possible to change the plugin/file capabilities so only the website owner can use it. Possibly making it so 'id=1' can only use this feature.

Thanks.
Yes.

In repfuck.php, edit this line:
Code:
if(!in_array($mybb->user['usergroup'], array('3','4'))) //Checks if user is Admin, or a super moderator

In your reputation.php, edit this line:
Code:
if(!in_array($mybb->user['usergroup'], array('3','4',)))
(Oct 16, 2011, 01:14 PM)F4T4L 3RR0R Wrote: [ -> ]Yes.

In repfuck.php, edit this line:
Code:
if(!in_array($mybb->user['usergroup'], array('3','4'))) //Checks if user is Admin, or a super moderator

In your reputation.php, edit this line:
Code:
if(!in_array($mybb->user['usergroup'], array('3','4',)))

Thanks, will this surely prevent my admins and mods from using it too?
Well, you need to set the 3 and 4 to whatever groupid you want to be able to use the plugin.

Make a test account and make it a mod/admin and test it.
(Oct 16, 2011, 09:11 PM)F4T4L 3RR0R Wrote: [ -> ]Well, you need to set the 3 and 4 to whatever groupid you want to be able to use the plugin.

Make a test account and make it a mod/admin and test it.

I made a new group named Creator with the id as '8'. Although whenever I changed the file settings so it shows group ID as '8' and nothing else the repFuck button doesn't appear on my screen. It only shows add reputation. I made a test account and gave it administrator and the repFuck button shows on that account.
(Oct 16, 2011, 09:15 PM)uzi Wrote: [ -> ]
(Oct 16, 2011, 09:11 PM)F4T4L 3RR0R Wrote: [ -> ]Well, you need to set the 3 and 4 to whatever groupid you want to be able to use the plugin.

Make a test account and make it a mod/admin and test it.

I made a new group named Creator with the id as '8'. Although whenever I changed the file settings so it shows group ID as '8' and nothing else the repFuck button doesn't appear on my screen. It only shows add reputation. I made a test account and gave it administrator and the repFuck button shows on that account.

Post the code edits you made here.

And just so you know, you can't manually set the id of a group. Go in your usergroups options in ACP and count from top to bottom until you reach the Creator group. The number you get is the groupid.