Support only during business hours : Monday to friday, from 8:30 am – 5:30 pm CEST

Due to the decrease in our staff due to vacations, our response time may be longer.

Be sure we're doing our best to manage your topic as soon as possible.

BuddyPress Profile Avatars

This topic is resolved
Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • Alongar
    Participant
    • 24 Topics
    • 70 Posts
    @alongar

    Hello,

    There are two issues I have:

    The first issue is related to BuddyPress. My avatar is from gravatar.com and before before I installed BuddyPress, the theme and WordPress native functions used the Gravatar. After installing BuddyPress, BuddyPress disabled that functioned. However after researching, BuddyPress is supposed to use Gravatar if photo uploads are disabled. So my profile picture is a default BuddyPress picture. How do I make BuddyPress use Gravatar and is the theme conflicting with BuddyPress using it?

    Second issue I have:

    Under the ‘Change Profile Photo’ section, a text appears Your profile photo will be used on your profile and throughout the site. To change your profile photo, please create an account with Gravatar using the same email address as you used to register with this site.

    The HTML code shows for the Gravatar link. Is there a fix to make the “Gravatar” a clickable link that directs to https://gravatar.com. I attached the a screenshot to better understand what the issue is.

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 4913 Posts
    @themodactyl

    Hi Alongar,

    Indeed, BuddyPress uses Gravatar by default. However, not everyone has a Gravatar account, especially in a community website. To prevents the user to have a blank avatar, our theme set a default one to each member, like the one in your screenshot.

    Be aware that you can allow your users to set an avatar directly from your website. Can you please go to Dashboard > Settings > BuddyPress > Options > Members Settings and make sure the feature “Allow registered members to upload avatars” is checked? Please find the attached screenshot.

    Thank to this feature, you will not have this gravatar message displayed and your users will be able to set an avatar more easily.

    Let me know if you need more explanations.

    Best,

    Alongar
    Participant
    • 24 Topics
    • 70 Posts
    @alongar

    I do not want my users to upload pictures but instead use a Gravatar. Is there a way to disable the theme’s default pic. Also, in the screenshot I provided, the HTML code shows in the description about a Gravatar.

    Alongar
    Participant
    • 24 Topics
    • 70 Posts
    @alongar

    Just an update

    I overridden the theme’s default avatar by creating a bp-custom.php file and using these constants:

    define ( 'BP_AVATAR_DEFAULT', $img_url );
    define ( 'BP_AVATAR_DEFAULT_THUMB', $img_url );

    This snippet works and overrides the theme’s default avatar photo.

    However, while using those constants, I wanted BuddyPress to use Gravatar if a user has one so I also added this constant:

    add_filter( 'bp_core_avatar_default', function() {
        return BP_AVATAR_DEFAULT;
    } );

    It does not display users Gravatar’s and only displays the default image constant that I set in the override. So not sure where to go from there. And still the HTML code is showing in the Change Profile Photo tab. Any ideas on how to fix that issue? Is it theme related?

    Alongar
    Participant
    • 24 Topics
    • 70 Posts
    @alongar

    *Update 2*

    I fixed the issue with the message displaying the HTML code link to Gravatar. The issue was with the Grimlock BuddyPress Plugin under the change-avatar.php file (grimlock-buddypress/templates/members/single/profile/change-avatar.php). On line 75 the code is:

    <p><?php esc_html_e( ‘Your profile photo will be used on your profile and throughout the site. To change your profile photo, please create an account with <a href=”https://gravatar.com”>Gravatar</a> using the same email address as you used to register with this site.’, ‘buddypress’ ); ?></p>

    The first part should be <?php _e not <php esc_html_e.

    The fixed code is:

    <p><?php _e( 'Your profile photo will be used on your profile and throughout the site. To change your profile photo, please create an account with <a href="https://gravatar.com">Gravatar</a> using the same email address as you used to register with this site.', 'buddypress' ); ?></p>

    So basically, my only issue now is Gravatars not showing if users have registered emails with gravatar.com and register to the site using that email. I changed the default avatar using the constants I posted in the previous comment and have it to where BuddyPress should be pulling user Gravatars if they have one instead of displaying the default avatar.

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 4913 Posts
    @themodactyl

    Hi Carm,

    Thank you for your patience.

    To allow your users to use Gravatar, simply add the following code snippet to your website:

    /**
    * Activate Gravatar 
    */
    add_filter( 'bp_core_fetch_avatar_no_grav', '__return_false', 100 );

    To add this code snippet to your site, we recommend that you use the Code Snippets plugin (https://wordpress.org/plugins/code-snippets/). If you have never activated this plugin, please read the following post: Adding Custom PHP Without Changing Your Child Theme.

    Please also note that we don’t provide any theme customization. So, you shouldn’t expect other snippets from us unless it’s to fix an issue stemming from our own codebase. We always try our best to help theme users whenever we can and only provide code snippets out of courtesy to prevent them from waiting for the next update.

    Concerning the html code link to Gravatar, it seems there is definitely an issue in our theme which will be fixed in the next update. We thank you for sharing the solution with us. I’m sure it will help other users facing the same issue. By doing this, you will be making a great contribution to this forum, and we thank you very much for that! #SharingIsCaring 💪🏻

    We’ll be back to you as soon as the update is available.

    Best,

    Alongar
    Participant
    • 24 Topics
    • 70 Posts
    @alongar

    Thank you. I will try the code snippet tomorrow.

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 4913 Posts
    @themodactyl

    You’re welcome Carm. 🙂

    Best,

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 4913 Posts
    @themodactyl

    Hi Carm,

    We have just released a new update of Grimlock for BuddyPress. Updating this plugin to the latest version should hide the Gravatar notice.

    After the update, the problem should now be fixed. However, you might still be seeing the issue because your browser cache is showing you an older version of the page (browsers do that to load pages faster). To see that the issue is resolved you will need to empty your browser cache and reload the page. If you want to read more on what browser cache is and how to clear it, here is an article that might help you: How to Clear Internet Cache in Every Major Browser.

    Kindest regards,

Roboraptor 🦖
Themosaurus Topic Closer

Hi there,

This topic has been inactive for a while now so we will be closing it to keep the forum tidy. Don't hesitate to create a new topic if you still need help and we'll be glad to help you!

Best regards,
The Themosaurus team.

Viewing 9 posts - 1 through 9 (of 9 total)

The topic ‘BuddyPress Profile Avatars’ is closed to new replies.

Troubleshooting Demo Imports

You're trying to setup your theme but you're experiencing errors when importing the demo content? Or you've just followed the setup guide but your website doesn't look exactly like our demo? These are common issues for which you can find easy and quick fixes.

Happy With our Support So Far?

Feel free to review our theme on Themeforest! It helps us making our products more known to new potential customers, which allow us more time to improve the quality and develop new features. #SharingIsCaring ❤️

Discover MatchPress

Skip • Like • Super-Like

Add powerful matching features like Member likes, skips, super likes, conditional private messaging and much more.