MyBB Community Forums

Full Version: Create User?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I've created some user accounts but they are showing up in the member list & as new member. Is there any way to set it so they don't show up until they activate their account?
No, as far as I know.
There might be:

Create another group by going to:

ACP > Users & Groups > Groups > Add New User Group:

After that, name that group. When its done, add the members to the new group. Then Edit that group & Uncheck this box:

Quote:Yes, show this group on the 'forum team' page

That way, they will not show up in the forum group team Smile
I mean so that they will not show up in the member list or on the newest member at the bottom of the forum. I don't want them to show up until they activate their account.
Open ./memberlist.php and find;
		$plugins->run_hooks("memberlist_user");
and add the following code just Below that;
		$uids = array(11,12);
		if (in_array($user['uid'],$uids) && $mybb->user['usergroup'] != "4")
		{
			continue;
		}

Replace 11,12 with the UserIDs you wish to hide them from memberlist.php.

Now with this modification, only Admins (who have usergroup ID = 4) can still see those userids. All other groups will not see those Users Wink

OR if you want to hide Non-Activated users then replace above code with this;

		if ($user['usergroup'] == "5" && $mybb->user['usergroup'] != "4")
		{
			continue;
		}
I tried this

if ($user['usergroup'] == "5" && $mybb->user['usergroup'] != "4")
{
continue;
}

but it's still showing them.



I have a question about the first code. The Awaiting Activation should be number 5 right? So would I put 5 where the 11,12 is?

Also is it posible to use both codes?
(2011-05-12, 06:18 AM)mxx Wrote: [ -> ]I tried this

if ($user['usergroup'] == "5" && $mybb->user['usergroup'] != "4")
{
continue;
}

but it's still showing them.



I have a question about the first code. The Awaiting Activation should be number 5 right? So would I put 5 where the 11,12 is?

Also is it posible to use both codes?

It shows to only you (If you are admin having usergroup id = 4) all other groups will not see those users in memberlist page.. Have you tried to view them from any other account or viewing the page as a guest ?
oh ic now. Can I use both codes?
Also how can I stop them from showing up on the newest member on the index page?
You can join both the codes like this;
		$uids = array(11,12);
		if (in_array($user['uid'],$uids) || $user['usergroup'] == "5" && $mybb->user['usergroup'] != "4")
		{
			continue;
		}

For index, I've posted a tip before on this site, but can't remember where it is now. If I found I'll post it here again Smile
do I leave the 11,12?
Pages: 1 2