Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Template Modifications
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Default Avatar For Members Without Details »»
Default Avatar For Members Without
Version: 1.00, by .LuTioN. .LuTioN. is offline
Developer Last Online: Jun 2004 Show Printable Version Email this Page

Version: Unknown Rating:
Released: 04-02-2004 Last Update: Never Installs: 2
 
No support by the author.

This mod will add a default avatar for members who have not selected an avatar. I haven't seen it released for vB3 Gold yet, so here it is

Some styles code in the postbit and postbit_legacy templates are different. If you are having trouble, just attach your postbit code to a post and I'll sort it out for you.

The only bug I could see is if a member chooses not to view avatars, he will see the default avatar for everyone.

Live demo at pCn Forums

Please click install

Show Your Support

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

Comments
  #2  
Old 04-03-2004, 01:21 AM
Diva's Avatar
Diva Diva is offline
 
Join Date: Oct 2001
Location: CA, USA
Posts: 311
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi .LuTioN.! I've been looking for this hack.

I tried it and the only problem is that if there is no avatar the username goes below the noavatar.gif.

Here is the code I used (the postbit is different from the p-legacy:

Code:
<if condition="$show['avatar']"><td class="alt2"><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$avatarurl" alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a>

PS: I'm using VB3G
Reply With Quote
  #3  
Old 04-03-2004, 01:25 AM
Zachery's Avatar
Zachery Zachery is offline
 
Join Date: Jul 2002
Location: Ontario, Canada
Posts: 11,440
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Add a div around his code for the second one.
Reply With Quote
  #4  
Old 04-03-2004, 01:28 AM
Diva's Avatar
Diva Diva is offline
 
Join Date: Oct 2001
Location: CA, USA
Posts: 311
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmmm... I dont think I understand where to put the <div>. I tried this and nothing happened:

Code:
<if condition="$show['avatar']"><td class="alt2"><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$avatarurl" alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a>
				</td><else /><div class="smallfont"><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="images/avatars/noavatar.gif" alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a></div>
                        </if>
Reply With Quote
  #5  
Old 04-03-2004, 01:42 AM
.LuTioN. .LuTioN. is offline
 
Join Date: Jan 2004
Posts: 30
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sorry, fixing code now. Will update in a few minutes.
Reply With Quote
  #6  
Old 04-03-2004, 02:15 AM
.LuTioN. .LuTioN. is offline
 
Join Date: Jan 2004
Posts: 30
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

@Diva

Attachment updated, but it's working on my forum and I'm using the same code. Try this if you can't get the code to work:

Find:
Code:
<if condition="$show['avatar']"><td class="alt2"><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$avatarurl" alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a></td></if>
Add After:
Code:
<if condition="!$show['avatar']"><td class="alt2"><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="images/avatars/noavatar.gif" alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a></td></if>
This code worked on my forum also.

And make sure your option to view avatars is checked in your userCP.

If anymore problems, please attach your postbit code to a post.
Reply With Quote
  #7  
Old 04-03-2004, 02:24 AM
Diva's Avatar
Diva Diva is offline
 
Join Date: Oct 2001
Location: CA, USA
Posts: 311
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yay! It works. Thank you two so much. *clicks install*
Reply With Quote
  #8  
Old 04-03-2004, 02:25 AM
.LuTioN. .LuTioN. is offline
 
Join Date: Jan 2004
Posts: 30
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Your welcome

Which option did you choose to fix it?
Reply With Quote
  #9  
Old 04-03-2004, 02:04 PM
Diva's Avatar
Diva Diva is offline
 
Join Date: Oct 2001
Location: CA, USA
Posts: 311
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

The one that you posted that you said also worked in your forum. This is a big help. Thanks again.
Reply With Quote
  #10  
Old 04-03-2004, 03:54 PM
.LuTioN. .LuTioN. is offline
 
Join Date: Jan 2004
Posts: 30
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Your welcome.
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 07:20 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.08447 seconds
  • Memory Usage 2,290KB
  • 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
  • (4)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_onlinestatus
  • (10)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_postinfo_query
  • fetch_postinfo
  • 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
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete