The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Place Avatar in VB and Non-VB Pages Details »» | |||||||||||||||||||||||||||
Place Avatar in VB and Non-VB Pages
Developer Last Online: Apr 2010
The following is a bit of code I came up with to continue to use the Avatar in Navbar mod by fraghappy. After searching for many hours I decided just to figure it out myself.
On the bright side, none of the plugins and db queries from the old mod are used. I'll try to support this as much as possible, but I don't foresee anyone having any real issues. It's pretty straight forward. Don't forget to click the INSTALL Features in progress
You just need to become familiar with the following bit of code: This will display a users avatar: Code:
<img src="$vboptions[bbdir]/image.php?u=$bbuserinfo[userid]" alt="Your avatar" border="0" /> In navbar template replace: Code:
<table cellpadding="0" cellspacing="0" align="left" style="margin-top:5px;"> <tr> <td><a href="profile.php?$session[sessionurl]do=editavatar"><img src="$navbar_ava[0]" alt="Your avatar" border="0" /></a> </td> Code:
<table cellpadding="0" cellspacing="0" align="left" style="margin-top:5px;"> <tr> <td><a href="$vboptions[bbdir]/profile.php?$session[sessionurl]do=editavatar"><img src="$vboptions[bbdir]/image.php?u=$bbuserinfo[userid]" alt="Your avatar" border="0" /></a> </td> Code:
<table cellpadding="0" cellspacing="0" align="left" style="margin-top:5px;"> <tr> <td><a href="$vbpoptions[bbdir]/profile.php?$session[sessionurl]do=editavatar"><img src="$vbpoptions[bbdir]/image.php?u=$bbuserinfo[userid]" alt="Your avatar" border="0" /></a> </td> Personally I don't use the no avatar image as the default. I created a custom default avatar for each usergroup. As for the plugin for the original Avatar on Navbar mod, I don't even use it. With this bit of code it's simple and not needed. or if you want to call it directly using an http: use this method: Code:
<table cellpadding="0" cellspacing="0" align="left" style="margin-top:5px;"> <tr> <td><a href="http://www.yourwebsite/pathtoforums/profile.php?$session[sessionurl]do=editavatar"><img src="http://www.yourwebsite/pathtoforums/image.php?u=$bbuserinfo[userid]" alt="Your avatar" border="0" /></a> </td> Enjoy! 07/28/2008 - Added simple screenshot. Show Your Support
|
Comments |
#2
|
|||
|
|||
Thank you very much, But I have one question, for those who have Big Avatars will this Mod resize the Avatar for what ever pixels want it?
Thank you </installed> |
#3
|
||||
|
||||
My attempts to contact the author of Show User's Avatar in Navbar v1.1, fraghappy have been unsuccessful. I'll try to make this into a product with <if> functions to call a default avatar if no custom avatar exists.
None of the original authors code is needed using this method so there shouldn't be an issue! |
#4
|
||||
|
||||
Quote:
I'd like to have it resize just for the navbar only and then add some ajax function to it so that it expands on mouse over. I'll keep everyone posted on the progress! |
#5
|
|||
|
|||
Quote:
|
#6
|
|||
|
|||
super cool mod
|
#7
|
|||
|
|||
Can we see a demo please..
|
#8
|
|||
|
|||
Quote:
Cant wait for the resize image function. |
#9
|
||||
|
||||
1) First Create a separate Avatar Category for each Usergroup:
In your admincp go to Avatars> Avatar Manager> Create New Avatar Category 2) Go to Avatars> Avatar Manager> (Usergroup Category) Avatar Permissions and select "No" for all usergroups except "Administrators" and the usergroup you setup the category for. Repeat this step for all the other Usergroup Categories you made. 3) Go to Avatars> Upload Avatar and select the image you use as your "NoAvatar" image. Set the Minimum Posts field to "0" and select the category that will use it. Give it a Title and click UPLOAD. Note: You can use the same image for each usergroup category but you must upload it for each one separately. Repeat this upload step for each user. I only use two usergroup categories so and both have individual images. I hope this helps you out! |
#10
|
|||
|
|||
thanks for the explanation!
now I'm trying to set an avatar as default so that when a user registers the avatar is already selected in his or her account instead of 'no avatar specified'. Is this possible? |
Thread Tools | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|