MyBB Community Forums

Full Version: display username styles with {username}?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I would like to display not just your username, but your username styles as well. Is this possible?

http://gyazo.com/0ba800a7ea3fd5b5dc50be4b401ed51d

Username: Test
Password: Password

The original "admin" style is green.

I have it like this:
<a href="{$mybb->settings['bburl']}/member.php?action=profile&uid={$mybb->user['uid']}" >{$mybb->user['username']}</a>

http://www.Vizzy.VisualizeEdits.com/
style used for the user groups (guide) works at some places - but not everywhere on the forum.
a couple of plugins (eg.) & code modifications exist for showing the user name with group style
(2013-07-12, 07:56 AM).m. Wrote: [ -> ]style used for the user groups (guide) works at some places - but not everywhere on the forum.
a couple of plugins (eg.) & code modifications exist for showing the user name with group style

I realized that you can add styles to username by groups but let say a member with a certain style in their username logged in, and that username in the picture will display their style with their username. I can't use something like

<a href="{$mybb->settings['bburl']}/member.php?action=profile&uid={$mybb->user['uid']}" >{$mybb->user['<style>username</style>']}</a>

It's just for those who have styles in their username to see, it's not really necessary.
Get Template Conditionals plugin (remember about copying .txt to plugins folder): http://mybbhacks.zingaburga.com/showthread.php?tid=464

Activate it, then put this in any template:
<setvar formatted_uname>format_name(htmlspecialchars_uni($mybb->user['username']), $mybb->user['usergroup'], $mybb->user['displaygroup'])</setvar>
{$tplvars['formatted_uname']}