How to get the avatar next to the personale messages box ?

Virtueel

New Member
I have the following problem, i dont know how to get the avatar and the letter icon next to my private message box at the top.

At the moment it is yust like this:
2ytw7tf.jpg


But i want to have it like this:
2z8u78x.jpg


Can anyone tell me how to get the letter icon over there, and how to display my avatar also at the top ?
 

k_hunter

New Member
open you navbar template and find:
==================================
<else />

<td class="alt2" nowrap="nowrap" style="padding:0px">

<!-- login form -->
==================================

add above
==================================
<td class="alt1"><a href="$vboptions[bburl]/profile.php?do=editavatar">$navbaravatar</a></td>
==================================


now upload the plugin and you're done.

Plugin goes to your "global_start" hook location, under the product of "vBulletin" and should be active.

Save this as navbaravatar-plugins.xml and upload via plugin manager. I was trying to attach it but I can't so decided to just code it.

Code:
<?xml version="1.0" encoding="ISO-8859-1"?>

<plugins>
	<plugin active="1" product="vbulletin">
		<title>Avatar In NavBar</title>
		<hookname>global_start</hookname>
		<phpcode><![CDATA[// Avatar In NavBar
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.gif\" alt=\"Your Avatar\" border=\"0\" />"; // "<span class=\"smallfont\">No Avatar<br/ >Specified</span>";
	} 
} 
// Avatar In NavBar]]></phpcode>
	</plugin>
</plugins>

For the mail thing, I don't know yet. :D
 

Virtueel

New Member
haha he still doesnt desirve it. I couldnt got the picture at the top. But instead i got a lot of errors. Maybe anyone else can help me how to fix this ?
 

Filez

New Member
Virtueel anytime someone goes to that much trouble and tries to FIX YOUR DAM PROBLEM......the very least you can do is say thanks......don't be an ungrateful shit!
 
Top