The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
![]()
Hi,
I had Jose over at vb.com forums help me in getting my avatar onto the navbar on the left hand side, now like a idiot I reverted the navbar template but I forgot to copy the code that was in there. Now I cant contact Jose so I was wondering if anyone can help me out? he told me to create a plugin and use this code: Code:
if ($vbulletin->userinfo['avatarid']) { // using a predefined avatar $avatar = $db->query_first("SELECT avatarpath FROM " . TABLE_PREFIX . "avatar WHERE avatarid = " . $vbulletin->userinfo[avatarid] . ""); $avatarid = $avatar['avatarid']; $navbaravatar = "<img src=\"" . $vbulletin->options[bburl] . "/$avatar[avatarpath]\" alt=\"Your Avatar\" border=\"0\" />"; } else { // not using a predefined avatar, check for custom if ($avatar = $db->query_first("SELECT dateline, userid FROM " . TABLE_PREFIX . "customavatar WHERE userid = " . $vbulletin->userinfo[userid] . "")) { // using a custom avatar $navbaravatarurl = ($vbulletin->options['usefileavatar']) ? "" . $vbulletin->options[avatarurl] . "/avatar$avatar[userid]_" . $vbulletin->userinfo[avatarrevision] . ".gif" : "" . $vbulletin->options[bburl] . "/image.php?u=" . $vbulletin->userinfo['userid'] . "&dateline=" . $avatar['dateline'] . ""; $navbaravatar = "<img src=\"$navbaravatarurl\" alt=\"Your Avatar\" border=\"0\" />"; } else { // no avatar specified $nouseavatarchecked = HTML_CHECKED; $avatarchecked[0] = ''; $navbaravatar = "<img src=\"" . $vbulletin->options[bburl] . "/$stylevar[imgdir_misc]/noavatar.jpg\" alt=\"Your Avatar\" border=\"0\" />"; // "<span class=\"smallfont\">No Avatar<br/ >Specified</span>"; } } ![]() thanks Dan |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|