Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Place Avatar in VB and Non-VB Pages Details »
Place Avatar in VB and Non-VB Pages
Mod Version: 1.00, by carmichael1973 (Member) carmichael1973 is offline
Developer Last Online: Apr 2010 I like it Show Printable Version Email this Page

This modification is in the archives.
vB Version: 3.7.0 Rating: (2 votes - 5.00 average) Installs: 33
Released: 27 Jul 2008 Last Update: Never Downloads: 2
Not Supported Template Edits Re-usable Code Translations Is in Beta Stage  

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

  • Add Auto-Resize for Navbar Only
  • Add AJAX function to expand to original size on mouse over
  • Definable default no avatar images for usergroups
  • AdminCP Options
  • Build as a simple product


You just need to become familiar with the following bit of code:

This will display a users avatar:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

and this is what I use in place of the Avatar in Navbar mod:

In navbar template replace:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

with this:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

In non-vb pages (i.e. vbp_navbar I use vbPortal) I use this code: You must modify this to match your portal or external pages


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Then just simply assign the noavatar.gif as the default avatar for your usergroups. From then on your users that have not uploaded a custom avatar will be displayed the noavatar.gif

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:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

The user must be logged in to the forums and using cookies to work outside of the forum root. If you are using an integrated portal system you should have no issues!

Enjoy!

07/28/2008 - Added simple screenshot.

Download Now

Only licensed members can download files, Click Here for more information.

Screenshots

Click image for larger version

Name:	nav_ava.jpg
Views:	1299
Size:	12.8 KB
ID:	84725  

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Comments
  #2  
Old 27 Jul 2008, 19:17
FReeSTER FReeSTER is offline
 
Join Date: Jun 2006
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>
Reply With Quote
  #3  
Old 27 Jul 2008, 19:25
carmichael1973's Avatar
carmichael1973 carmichael1973 is offline
 
Join Date: Aug 2006
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!
Reply With Quote
  #4  
Old 27 Jul 2008, 19:33
carmichael1973's Avatar
carmichael1973 carmichael1973 is offline
 
Join Date: Aug 2006
Originally Posted by El Intocable View Post
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>
No it doesn't! I am working on adding the resize image function just like when you add a custom avatar through the admincp. At this point I advertise max avatar sizes. My users have been pretty good about resizing thier own images.

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!
Reply With Quote
  #5  
Old 27 Jul 2008, 19:49
FReeSTER FReeSTER is offline
 
Join Date: Jun 2006
Originally Posted by carmichael1973 View Post
No it doesn't! I am working on adding the resize image function just like when you add a custom avatar through the admincp. At this point I advertise max avatar sizes. My users have been pretty good about resizing thier own images.

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!
Thank you mate, very nice of you
Reply With Quote
  #6  
Old 28 Jul 2008, 18:28
zmmmzz zmmmzz is offline
 
Join Date: Nov 2007
super cool mod
Reply With Quote
  #7  
Old 28 Jul 2008, 18:51
RobbieZ RobbieZ is offline
 
Join Date: Jul 2008
Can we see a demo please..
Reply With Quote
  #8  
Old 28 Jul 2008, 19:38
zmmmzz zmmmzz is offline
 
Join Date: Nov 2007
Then just simply assign the noavatar.gif as the default avatar for your usergroups
How do I do this?

Cant wait for the resize image function.
Reply With Quote
  #9  
Old 29 Jul 2008, 00:52
carmichael1973's Avatar
carmichael1973 carmichael1973 is offline
 
Join Date: Aug 2006
Originally Posted by zmmmzz View Post
How do I do this?

Cant wait for the resize image function.
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!
Reply With Quote
  #10  
Old 29 Jul 2008, 05:15
zmmmzz zmmmzz is offline
 
Join Date: Nov 2007
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?
Reply With Quote
  #11  
Old 29 Jul 2008, 05:32
carmichael1973's Avatar
carmichael1973 carmichael1973 is offline
 
Join Date: Aug 2006
Lightbulb

Originally Posted by zmmmzz View Post
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?
It is possible.... If you can give me another couple of days I'll have a total solution for you. Then the above steps won't be needed. I'm very close on this but work is taking alot of my time.

Last edited by carmichael1973; 29 Jul 2008 at 05:38.
Reply With Quote
  #12  
Old 29 Jul 2008, 18:21
zmmmzz zmmmzz is offline
 
Join Date: Nov 2007
ok! cant wait
thank you for taking time for this
Reply With Quote
  #13  
Old 04 Aug 2008, 19:19
trulylowcarb's Avatar
trulylowcarb trulylowcarb is offline
 
Join Date: Apr 2004
Real name: Karen
Thank you! I was looking for the right code to display avatars in the navbar. I need them to be smaller, too, though.
*installed*
Reply With Quote
  #14  
Old 04 Aug 2008, 20:20
trulylowcarb's Avatar
trulylowcarb trulylowcarb is offline
 
Join Date: Apr 2004
Real name: Karen
I am sure it is a dirty cheat, but I just used the html to call the avatar directly in my navbar, then added width="25%" height="25%". It seems to work perfectly. For those with no avatar, the space is just blank. I would really like to use the default avatar instead though, I haven't found anything to do that in anything even close to the current version and I have a lot usergroups, so ....
<crossing fingers you'll put it all together for us>
Reply With Quote
  #15  
Old 04 Aug 2008, 20:33
trulylowcarb's Avatar
trulylowcarb trulylowcarb is offline
 
Join Date: Apr 2004
Real name: Karen
I take it back - it doesn't update when the avatar is changed or deleted.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 19:32.

Layout Options | Width: Wide Color: