Quote:
Originally Posted by beano33
I'd like to use this, but restrict it by usergroup (paid subscribers). Is it simply a matter of changing this
PHP Code:
if (!$show['btu_canban'] AND !is_first_poster($threadid))
to
PHP Code:
if (!$show['btu_canban'] AND !is_first_poster($threadid) AND !is_member_of($bbuserinfo, x))
where x is the usegroup I want to give permission to?
|
Hi,
the threadstarter and a member of a group can now ban/unban users from his/a thread.
1.
AdminCP ->
Plug-ins & Products ->
Plugin Manager
Look for btu_manager -> (Hook) threadmange_start
Open and search for (line 98)
PHP Code:
if (!$show['btu_canban'])
After
PHP Code:
if ($_REQUEST['do'] == 'btu_ban')
{
Replace with
PHP Code:
if (!$show['btu_canban'] AND !is_first_poster($threadid) AND !is_member_of($vbulletin->userinfo, x)
x = your UsergroupID
Save
2.
Add New Plugin:
Product -> Ban Thread User
Hook Location (Hook) -> postbit_display_complete
Title -> btu_canban threadstarter
Execution Order -> 5
Plugin PHP Code ->
PHP Code:
$show['btu_canban'] = ($this->registry->userinfo['userid'] AND $post['userid'] AND $post['userid'] != $this->registry->userinfo['userid'] AND (($this->registry->userinfo['permissions']['adminpermissions'] & $this->registry->bf_ugp_adminpermissions['ismoderator']) OR $thread['postuserid'] == $this->registry->userinfo['userid'] OR is_member_of($this->registry->userinfo, x)));
Plugin is Active? -> Yes
x = your UsergroupID
Save
Kind Regards,
St?bi