The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
display the memberes of a certain usergroup as a vertical list one per line?
I would like to be able to incorporate a list of users in a "right colum code" hack that i have on my board, is there a way to do this? I just need it to list one user per line as seen on my current board, except this list is done manually, i'd like to to autoupdate as the members in the usergroup change.
http://www.okgmp.com you can see the list on the right about middle way. |
#2
|
||||
|
||||
Try this; create a new plugin at forumhome_start with the following:
Code:
$query = $db->query_read("SELECT username,userid FROM user WHERE usergroupid = 'X'"); while($row = mysql_fetch_array($query)) { eval('$usernames .= "' . fetch_template('forum_users_bit') . '";'); } Then create a new template named "forum_users_bit" with the following: Code:
<a href="member.php?u=$row[userid]">$row[username]</a>, You can fiddle with it yourself if you're not trying to place it on the forumhome. |
#3
|
|||
|
|||
looks simple enough, just one other question.
Okay seems to work fine in the forumhome, how can I make it work in the "RightColumn" template? do I need to move the HOOK to somewhere or something? sorry I'm not too good with coding.. |
#4
|
||||
|
||||
Where is your Right Column being placed? You'd probably be fine just changing the Hook's location from "forumhome_start" to "global_start". This'll make it available on the majority of templates.
|
#5
|
|||
|
|||
the right column has it's own template off of the root (i guess you could say) it's not a sub template in any other template. the varible for the right column code is in the forum home template. I'll try moving the hook location to global and see what happens.
thanks for the help! ***EDIT*** hmm.. still no workie I moved the hook location to global_start but still nothing in the right column. weird. |
#6
|
|||
|
|||
anyone? surely someone knows how to do this?
all the code is working right I guess I just need to find the correct place to put my hook? I tried Global but it doesn't work. |
#7
|
|||
|
|||
I'm in the same boat. Can anyone help?
|
#8
|
|||
|
|||
Anyone ever get this to work? Would still like to do this.
|
#9
|
||||
|
||||
I would like to the list members in a secondary usergroup. I've changed "usergroupid" to "membergroupids". With "usergroupid" all members of the primary usergroup (X) are displayed however with"membergroupids" only one (1) member of the secondary usergroup (X) is being displayed. Any ideas?
Code:
$query = $db->query_read("SELECT username,userid FROM user WHERE membergroupids = '51'"); while($row = mysql_fetch_array($query)) { eval('$usernames .= "' . fetch_template('forum_users_bit') . '";'); } |
#10
|
||||
|
||||
Hmm... did anyone ever figure this out? It seems to be working in the origional thread starters' page, but I can't get it working on mine.
EDIT: got it working, nevermind. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|