MyBB Community Forums
Lastmember usergroup colour on index page - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: Extensions (https://community.mybb.com/forum-201.html)
+--- Forum: Plugins (https://community.mybb.com/forum-73.html)
+---- Forum: Plugin Requests (https://community.mybb.com/forum-65.html)
+---- Thread: Lastmember usergroup colour on index page (/thread-31437.html)



Lastmember usergroup colour on index page - Indy74 - 2008-05-12

Hello.

I want the name of the last member on index page, to be colorized according to his/her membergroup colour.

I've tried to change this in index.php:
$newestmember = build_profile_link($stats['lastusername'], $stats['lastuid']);

Into this:
$newestmember = build_profile_link(format_name($stats['lastusername'], $stats['usergroup'], $stats['displaygroup']), $stats['lastuid']);
But nothing changed.

I guess i'm missing something ;P


RE: Lastmember usergroup colour on index page - LeX- - 2008-05-12

Change it into this;

		$newmem = get_user($stats['lastuid']);
		$newestmember = build_profile_link(format_name($stats['lastusername'], $newmem['usergroup'], $newmem['displaygroup']), $stats['lastuid']); 

the usergroup and displaygroup aren't stored in the statscache.


RE: Lastmember usergroup colour on index page - Indy74 - 2008-05-12

Thanks.Big Grin