Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Not Solved [How To?] Need a little help in permission
#4
Not Solved
Ask someone to create a simple plugin I just don't have time sorry!

Here is a plugin not tested so don't know if it'll work but I hope someone will fix it Smile

<?php

$plugins->add_hook('showthread_start', 'VIP');
function VIP_info()
{
	return array(
		"name"			=> "VIP member",
		"description"	=> "Users that are not in this group will be redirected to VIP page",
		"compatibility"	=> "16*"
	);
}




function VIP()
{
	global $mybb;
	if (!in_array($mybb->user['usergroup'], array(3, 4, 6))) {
		header("Location: http://www.letsforum.com"); /* Redirect browser */
exit();
	}
	
}

?>

Remember to change redirect URL Smile

Or use:

if (!in_array($mybb->user['usergroup'], array(3, 4, 6))) {
		error("error message");
	}


Messages In This Thread
Need a little help in permission - by VIP3R69 - 2014-03-13, 09:45 AM
RE: Need a little help in permission - by VIP3R69 - 2014-03-14, 06:40 AM
RE: Need a little help in permission - by marcus123 - 2014-03-14, 09:54 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)