Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Avatar On Navbar Details »»
Avatar On Navbar
Version: 1.00, by sabret00the sabret00the is offline
Developer Last Online: Apr 2010 Show Printable Version Email this Page

Version: 3.5.0 Rating:
Released: 10-27-2005 Last Update: 10-28-2005 Installs: 349
Uses Plugins Template Edits
 
No support by the author.

Erm, this add's a cool Avatar to your navbar but only for logged in users

something like that, i really need to think of ways to make this stuff more exciting.

fixed bug where pre-defined avatars wouldn't show.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #212  
Old 01-21-2008, 08:39 PM
Mark.B Mark.B is offline
Senior Member
 
Join Date: Feb 2004
Posts: 1,354
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by smooth-c View Post
Anyone got this working with 3.7?
It works for me on 3.7, all I had to do when I upgraded was to redo the template edits, apart from that it carried on working with no changes.
Reply With Quote
  #213  
Old 01-21-2008, 11:39 PM
smooth-c smooth-c is offline
 
Join Date: Jan 2008
Posts: 226
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Template edits? elaborate dood!
Reply With Quote
  #214  
Old 01-25-2008, 10:33 PM
Cobro Cobro is offline
 
Join Date: Oct 2006
Location: cellar
Posts: 136
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

works on vbulletin 3.6.8 thx
Reply With Quote
  #215  
Old 02-26-2008, 08:04 PM
odln018's Avatar
odln018 odln018 is offline
 
Join Date: Mar 2006
Posts: 210
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

There's a rather large border around my avatars, is there a way to lessen it?
Reply With Quote
  #216  
Old 02-28-2008, 09:02 AM
DrKNickel DrKNickel is offline
 
Join Date: Oct 2007
Posts: 52
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Me too!

How can i change the border around my avatar?

Greets

ME STUPID!

Just change the cellpadding in the table

Greets
Reply With Quote
  #217  
Old 02-28-2008, 08:40 PM
odln018's Avatar
odln018 odln018 is offline
 
Join Date: Mar 2006
Posts: 210
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Here's mine, what should I change?

Code:
/ 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\" height=\"50\" 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'] . "&amp;dateline=" . $avatar['dateline'] . "";
		$navbaravatar = "<img src=\"$navbaravatarurl\" alt=\"Your Avatar\" height=\"50\" 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\" height=\"50\" border=\"0\" />"; // "<span class=\"smallfont\">No Avatar<br/ >Specified</span>";
	} 
} 
// Avatar In NavBar
Reply With Quote
  #218  
Old 03-15-2008, 03:41 PM
Mark.B Mark.B is offline
Senior Member
 
Join Date: Feb 2004
Posts: 1,354
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I can't honestly remember exactly what edits I made...and my navbar is a bit customised anyway....but the important things are that the functionality of this hack works fine in 3.7, all that needs to be done is to reapply the template edits after the upgrade and after reverting the templates.

The important thing to remember is that there are changes to the navbar template in 3.7 close to where this hack operates. Namely, the "your notifications" functionality. But the basics and the layout is still pretty much the same.

I don't have access to a 3.6 navbar template any more so I can't elaborate much more. But it relatively easy...I'm no coder and I did it quite easily.
Reply With Quote
  #219  
Old 03-16-2008, 02:37 AM
StarShaper StarShaper is offline
 
Join Date: Sep 2005
Posts: 17
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Tested with vB 3.7 Beta 6.

It Works! However the code has some silly parts, which should be corrected into this.

PHP 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="Avatar" width="" height="" border="0" />"
} else { 
    
// not using a predefined avatar, check for custom 
    
if ($avatar $db->query_first("SELECT dateline, width_thumb, height_thumb FROM " TABLE_PREFIX "customavatar WHERE userid = " $vbulletin->userinfo[userid] . "")) { 
        
// using a custom avatar 
        
$navbaravatarurl = ($vbulletin->options['usefileavatar']) ? "" $vbulletin->options['bburl'] . "/" $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="Avatar" width="" $avatar['width_thumb'] . "" height="" $avatar['height_thumb'] . "" border="0" />";
    } else { 
        
// no avatar specified 
        
$navbaravatar "<img src="" $vbulletin->options['bburl'] . "/$stylevar[imgdir_misc]/emptyavatar.gif" alt="No Avatar" width="" height="" border="0" />";
    } 

Reply With Quote
  #220  
Old 03-16-2008, 07:56 AM
Feckie (Roger)'s Avatar
Feckie (Roger) Feckie (Roger) is offline
 
Join Date: May 2005
Location: Dublin Eire
Posts: 392
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If you want this to show in ibproarcade, do the following.

1: In /arcade/functions/functions.php file..

find online 1241 approx ...
PHP Code:
global $header
Add after it
PHP Code:
 $navbaravatar
Save upload and enjoy....
Reply With Quote
  #221  
Old 03-16-2008, 08:49 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Feckie (Roger) View Post
If you want this to show in ibproarcade, do the following.

1: In /arcade/functions/functions.php file..

find online 1241 approx ...
PHP Code:
global $header
Add after it
PHP Code:
 $navbaravatar
Save upload and enjoy....

Or you can do as i do am do a $vbphrase[whatever] = $navbaravatar;

and use the phrase.
Reply With Quote
Reply


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

Forum Jump


All times are GMT. The time now is 12:29 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04916 seconds
  • Memory Usage 2,340KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (5)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete