Page 1 of 1

PCP Default avatar

PostPosted: Wed May 03, 2006 2:33 pm
Author: Threat009
Basically, It gives users w/no avatar a default avatar based on male, female, sex, etc. The default avatar is only present if/when that user decides to post, which is cool, but I would like the default avatar to be present in the user block, after the user has logged in. Anyone know how this can be done?

FYI:
Code: Select all
################################################################# ## MOD Title]http://www.web-lapin.levillage.org/forum/#[/url]# ## MOD Description: Gives you the possibility to show one avatar if the member is a male ##                  and another avatar if the member is a female. If the member have not ##                  choosen gender, a default avatar is use. ##                  it works only on users who have not choosen an avatar in their profile. ##                  Default avatar will be displayed in avatar panel , public panel and topics .## ## Requirement: Profile Control Panel 2.0.0## ## Installation Level: Easy ## Installation Time: 5 minutes #### Files To Edit: 2 ##                profilcp/def/def_userfuncs_std.php##                templates/subSilver/subSilver.cfg ## ## Included Files: 4 ##                 guest_avatar.gif ##                 no_avatar.gif ##                 no_avatar_male.gif ##                 no_avatar_female.gif ## ## ############################################################## ## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD #################################################################  # #-----[ COPY ]------------------------------------------ # copy templates/subSilver/images/lang_english/guest_avatar.gif to templates/subSilver/images/lang_english/guest_avatar.gifcopy templates/subSilver/images/lang_english/no_avatar.gif to templates/subSilver/images/lang_english/no_avatar.gifcopy templates/subSilver/images/lang_english/no_avatar_male.gif to templates/subSilver/images/lang_english/no_avatar_male.gifcopy templates/subSilver/images/lang_english/no_avatar_female.gif to templates/subSilver/images/lang_english/no_avatar_female.gif  # #-----[ OPEN ]------------------------------------------ #profilcp/def/def_userfuncs_std.php  # #-----[ FIND ]------------------------------------------ #     return $res;}  //-----------------------------------//// user_sig output function  # #-----[ BEFORE, ADD ]------------------------------------------ #     // Guest and default male/female avatar for PCP 2.0.0     else if ( empty($view_userdata[$field_name]) && $userdata['user_viewavatar'] && $view_userdata['user_allowavatar'] && ($view_userdata['user_id'] != ANONYMOUS) )     {         if ( $view_userdata['user_gender'] == '1')         {               $img = '<img>';         }         else if ( $view_userdata['user_gender'] == '2')         {               $img = '<img>';         }           else           {               $img = '<img>';         }           // result         $res = pcp_output_format($field_name, $txt, $img, $map_name);     }     else if ( $view_userdata['user_id'] = ANONYMOUS)     {         $img = '<img>';           // result         $res = pcp_output_format($field_name, $txt, $img, $map_name);     }     // Guest and default male/female avatar for PCP 2.0.0  # #-----[ OPEN ]------------------------------------------ # (make sure to edit file .cfg for every theme you use). #templates/subSilver/subSilver.cfg  # #-----[ FIND ]------------------------------------------ # ?>  # #-----[ BEFORE, ADD ]------------------------------------------ #  // Guest and default male/female avatar for PCP 2.0.0$images['default_avatar'] = "$current_template_images/{LANG}/no_avatar.gif"; $images['guest_avatar'] = "$current_template_images/{LANG}/guest_avatar.gif"; $images['default_avatar_male'] = "$current_template_images/{LANG}/no_avatar_male.gif"; $images['default_avatar_female'] = "$current_template_images/{LANG}/no_avatar_female.gif"; // Guest and default male/female avatar for PCP 2.0.0  # #-----[ SAVE/CLOSE ALL FILES ]------------------------------------------ # # EoM

Re: PCP Default avatar

PostPosted: Wed May 03, 2006 4:43 pm
Author: Threat009
Scratch that! I'm thinking it would prolly be easier just to force users to select avatar when registering. Anyway I can do this? I would like it to requests existing users to choose avatar as well. Thanx......

[color=red]Edit] Was checking out the P.C.P. and was able to set it up to force when register & what not, but got stuck on the values. Not sure I even have to do all of this. Just looking to display a default avatar when user is logged on. I think if people knew that thier avatar is displayed in thier user block they would be more likely to atleast customize that part of thier profile.....

Re: PCP Default avatar

PostPosted: Fri May 05, 2006 10:14 am
Author: Threat009
Sorry to double, triple post, but the posts pile up so quick here, wasn't sure if this had been overlooked. Anyway, still wondering if this can be done? Anybody w/any ideas? <img>

PostPosted: Fri May 19, 2006 2:26 pm
Author: foxyone
i use avatar generator its easier