MyBB Community Forums

Full Version: How to link profile name
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Sorry, it was quite hard to decide what type of title to use as I can't really explain it.

My coding knowledge is very little but I have spent about an hour trying to get it to work, to which I failed so I decided to try the forums for help.

[Image: 1eVnc]
Here.

Where it says "Welcome back {username}" I'd like it to link to "/member.php?action=profile"

<span style="float: right;"><img src="{$mybb->user['avatar']}"  style="vertical-align:middle;position:absolute;margin-left:-52px;margin-top:14px;" width="50px" height="50px" /></span>
Welcome back, {$mybb->user['username']}!<br />
You currently have {$mybb->user['unreadpms']} unread messages.<br />
You've made {$mybb->user['postnum']} posts.<br />
<a href="{$mybb->settings['bburl']}/usercp.php"><strong>User CP</strong></a> {$modcplink} {$admincplink}<br />
<a href="{$mybb->settings['bburl']}/member.php?action=logout&amp;logoutkey={$mybb->user['logoutkey']}">{$lang->welcome_logout}</a>

I attempted to edit it using original code from the bottom but it's hard.

How do I manage to link the user's profile when they click on their name?

Thanks.
Change:
Welcome back, {$mybb->user['username']}!<br /> 

To:
Welcome back, <a href="{$mybb->settings['bburl']}/member.php?action=profile&uid={$mybb->user['uid']}">{$mybb->user['username']}</a>!
(2012-10-14, 11:44 PM)x-Treme Wrote: [ -> ]Change:
Welcome back, {$mybb->user['username']}!<br /> 

To:
Welcome back, <a href="{$mybb->settings['bburl']}/member.php?action=profile&uid={$mybb->user['uid']}">{$mybb->user['username']}</a>!


Thank you for the help!
Worked perfectly.
Glad you got it sorted.