The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Details »» | |||||||||||||||||||||||||
This one is for CJ:
it allows you to select in a usergroup's settings whether the members of this usergroup will show up in the Members List. For example, on my Bulletin Board members of the "Banned Users" and "Users Awaiting Email Confirmation" are excluded and will not show up on the Members List. Others might find it useful if they want to exclude Administrators or other site personnel. In any case, it's a very simple hack (I think). It involves runnign one MySQL query and editing two scripts. Installation: 1. Run the following MySQL command via phpMyAdmin or Telnet: Code:
ALTER TABLE usergroup ADD showinlist SMALLINT (6) DEFAULT '1' not null 2. Open admin/usergroup.php. Find: PHP Code:
PHP Code:
Code:
candenypmreceipts,maxbuddypm,maxforwardpm) Code:
candenypmreceipts,maxbuddypm,maxforwardpm,showinlist) Code:
$maxbuddypm,$maxforwardpm) Code:
$maxbuddypm,$maxforwardpm,$showinlist) PHP Code:
PHP Code:
Code:
maxforwardpm=$maxforwardpm Code:
maxforwardpm=$maxforwardpm,showinlist=$showinlist 3. Open memberlist.php Find: PHP Code:
PHP Code:
Now, go to the Control Panel -> User Groups and Permissions -> Modify. Click on "edit" next to the usergroup you want to EXCLUDE from the Members List. (meaning: the members of that usergroup will not appear in the Members List). Under the "Miscellaneous Permissions" section you will find a yes/no option whether members of this usergroup will show up in the Members List or not. Cheers, Bira Show Your Support
|
Comments |
#2
|
||||
|
||||
One more thing.
I did not include this in the hack as it wasn't directly the same however I thought I'd mention this: On my Bulletin Board, users with 0 posts are excluded from the members list as well. If you are interested in this too (not showing users who never posted), then also do the following in memberlist.php: Find TWICE: Code:
WHERE $condition AND Code:
WHERE $condition AND posts!='0' AND Bira |
#3
|
|||
|
|||
This is great and on the lines of something I'm tying to achieve, but a little different. I want to have new members be able to join a particular group, show up in that groups membership list but not in other's. Sort of like having different lists for different groups but in actuallity everyone is in the same user table. Does that make any sense?
Well would I do something simular to this to achieve that or am I off base. |
#4
|
||||
|
||||
wajones, this can be achieved quite easily:
Open memberlist.php find: PHP Code:
PHP Code:
you will see only the users in usergroup whose id is xx example: http://www.atlasf1.com/bb/memberlist.php?usergroup=6 -- you will see all the members of the Administrator usergroup. *** Now here's another twist you can add. If you want a logged in user to see only members of his group, do the following instead: PHP Code:
|
#5
|
|||
|
|||
Great, Thank you very much!!!
|
#6
|
||||
|
||||
One more option for those interested:
If you want the "Registered Members: XXXX" on the BB's front page to NOT include those whom you excluded from the Members List (example: if you don't want Banned Users to be included in neither the Members List nor the total Members count), then do the following: Open index.php Find: Code:
$numbersmembers=$DB_site->query_first('SELECT COUNT(*) AS users,MAX(userid) AS max FROM user'); Code:
$condition="1=1"; $showugroup=$DB_site->query("SELECT usergroupid FROM usergroup WHERE showinlist=0"); while($thisgroup=$DB_site->fetch_array($showugroup)) { $condition.=" AND usergroupid!='$thisgroup[usergroupid]'"; } $numbersmembers=$DB_site->query_first('SELECT COUNT(*) AS users,MAX(userid) AS max FROM user WHERE $condition'); Bira |
#7
|
|||
|
|||
Fatal error: Call to unsupported or undefined function ????while() in /home/sites/site25/web/bb/memberlist.php on line 90
Is this a result of using non-supported functions by php3? Really, all I am looking for is a way to prevent (COPPA) Users to show up in the "Welcome to our newest user, XXXXX" And preferably a way to show (COPPA) Users on the index site, as links to their profiles. I tried to add this in the index.php: PHP Code:
Shouldn't this work? -net |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|