Results 1 to 6 of 6

Thread: Welcome Block problems w/ Disabling Avatar

  1. #1

    Default Welcome Block problems w/ Disabling Avatar

    I'm having some minor issues after upgrading to CMPS 3.01. I have the Welcome Block displayed on my homepage. It displayes the "no avatar selected" image even for users that have avatars.

    It is also set to not display the avatar and to be in brief mode. Neither of those settings are working. Any ideas? The diagnostics shows all okay except for the missing admincp/vbacmps_install.php file.

  2. #2
    Join Date
    Sep 2004
    Location
    HSV
    Posts
    276

    Default

    I'm having similar problems. I've set the welcome block to not display the avatar and it still does. My test site doesn't have any avatars, so it keeps displaying the 'no avatar' image.

    I've checked diagnostics, and it's kinda weird. Under version it says "version information in currently unavailable". It also says that vb cmps is disabled in installed products, but it's not. Everything else is showing ok.

    Any assistance appreciated.

  3. #3
    Join Date
    Jan 2004
    Location
    Georgia, USA
    Posts
    34,466

    Default

    Thank you for pointing this out. Looks like there was a small bug in the modules/welcomeblock.php file that was allowing the "no avatar" image to still be displayed. I've just applied the fix to that file in the download package here, so if you will download the files again and update that one on your server, then that should take care of the issue.
    Frequently Asked Questions
    CMPS Users Manual

    For vBadvanced software assistance, please use the support forums.
    Unsolicted PMs, IMs, and email will not be responded to.
    If you have a non-software related question or problem with your account, please submit a support ticket.

  4. #4
    Join Date
    Sep 2004
    Location
    HSV
    Posts
    276

    Default

    Thank you Brian!

    If the fix is minor enough, do you mind posting it here so I can just edit my file?

  5. #5
    Join Date
    Jan 2004
    Location
    Georgia, USA
    Posts
    34,466

    Default

    It's more than just a line or two that was changed, but you can look in the file for this code:

    PHP Code:
        // Avatar
        
    if ($mod_options['portal_welcome_avatar']
            AND 
    $vbulletin->userinfo['showavatars']
            AND (
    $vbulletin->userinfo['avatarid']
                OR (
    $vbulletin->userinfo['permissions']['genericpermissions'] & $vbulletin->bf_ugp_genericpermissions['canuseavatar'])
                OR 
    $vbulletin->userinfo['adminavatar']
            )
        )
        {
            require_once(
    DIR '/includes/functions_user.php');
            
    $avatarurl fetch_avatar_url($vbulletin->userinfo['userid']);

            if (
    $avatarurl[0])
            {
                
    $avatarurl $vbulletin->options['bburl'] . '/' $avatarurl[0];
            }
            else if (
    $mod_options['portal_noavatarurl'])
            {
                eval(
    '$mod_options[\'portal_noavatarurl\'] = "' addslashes($mod_options['portal_noavatarurl']) . '";');
                
    $avatarurl $mod_options['portal_noavatarurl'];
            }
        }
        else if (
    $vbulletin->options['avatarenabled'])
        {
            eval(
    '$mod_options[\'portal_noavatarurl\'] = "' addslashes($mod_options['portal_noavatarurl']) . '";');
            
    $avatarurl $mod_options['portal_noavatarurl'];
        } 
    And replace with this:
    PHP Code:
        // Avatar
        
    $avatarurl '';
        if (
    $mod_options['portal_welcome_avatar'])
        {
            if (
    $vbulletin->userinfo['showavatars']
                AND (
    $vbulletin->userinfo['avatarid']
                    OR (
    $vbulletin->userinfo['permissions']['genericpermissions'] & $vbulletin->bf_ugp_genericpermissions['canuseavatar'])
                    OR 
    $vbulletin->userinfo['adminavatar']
                )
            )
            {
                require_once(
    DIR '/includes/functions_user.php');
                
    $avatarurl fetch_avatar_url($vbulletin->userinfo['userid']);
        
                if (
    $avatarurl[0])
                {
                    
    $avatarurl $vbulletin->options['bburl'] . '/' $avatarurl[0];
                }
                else if (
    $mod_options['portal_noavatarurl'])
                {
                    eval(
    '$mod_options[\'portal_noavatarurl\'] = "' addslashes($mod_options['portal_noavatarurl']) . '";');
                    
    $avatarurl $mod_options['portal_noavatarurl'];
                }
            }
            else if (
    $vbulletin->options['avatarenabled'])
            {
                eval(
    '$mod_options[\'portal_noavatarurl\'] = "' addslashes($mod_options['portal_noavatarurl']) . '";');
                
    $avatarurl $mod_options['portal_noavatarurl'];
            }
        } 
    Frequently Asked Questions
    CMPS Users Manual

    For vBadvanced software assistance, please use the support forums.
    Unsolicted PMs, IMs, and email will not be responded to.
    If you have a non-software related question or problem with your account, please submit a support ticket.

  6. #6
    Join Date
    Sep 2004
    Location
    HSV
    Posts
    276

    Default

    Thank you very much Brian! *rushes to change code*

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Welcome Block Avatar size ?
    By Onehalfmoa in forum "How Do I..." Questions
    Replies: 2
    Last Post: 12-06-2008, 01:34 PM
  2. No avatar in usercp block
    By TsirhCitna in forum Troubleshooting & Problems
    Replies: 1
    Last Post: 06-13-2008, 06:21 PM
  3. User CP Block - Avatar
    By Morrow in forum Troubleshooting & Problems
    Replies: 2
    Last Post: 04-10-2006, 07:59 PM
  4. welcome block - avatar/profile pic
    By majorj0nny1 in forum Troubleshooting / "How do I..." Questions
    Replies: 3
    Last Post: 05-28-2005, 09:23 PM
  5. Avatar in news block.
    By bigcurt in forum Troubleshooting / "How do I..." Questions
    Replies: 6
    Last Post: 02-26-2005, 02:00 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •