January 18, 2015 at 6:20 am #6755
I’m not sure whether I do something wrong, but I cant get avatars from social services like Facebook to work.
I use WP Social Login plugin (https://wordpress.org/plugins/wordpress-social-login/) that enables users to login/register to wordpress via Facebook, Twitter etc. Everything works great but avatars in WPRSP dont load from Facebook/Twitter/etc profile.
Tried to change your code and hopefully found an easy solution:
in /libs/include/user-rating/wprs-aggregate-template.php change line #40
$gravatar_img = '<img class="avatar avatar-60 photo" src="http://www.gravatar.com/avatar/'.$gravatar_hash.'?d=mm&r=g" alt="'.$comment->comment_author.'" width="60" height="60" />';
$gravatar_img = get_avatar($comment->comment_author_email);
This way avatars load correctly (as far as I tested) and also load user profile photos from social services. WP Social Plugin integrates into wordpress correctly but since your code uses only gravatar avatars, it gets no use from Social Plugin avatar integration.
If changing the line is a problem, is it possible to add a new boolean setting to setting page (like “load avatars via WordPress settings”) and add my line to the code?
Or do you have another solution that I just dont see?
Thank you in advance!
January 21, 2015 at 8:52 am #6793
Editing the core code of the plugin isn’t a good idea, your changes will be overridden once you update the plugin to a newer version.
I’ve added a new option to allow you to switch within the plugin settings, under the Rating tab. This will be part of our next update.
January 21, 2015 at 4:21 pm #6798
Yeah, I know, thats why I asked about that settings thing you confirmed.
So thanks for that, looking forward it!
January 22, 2015 at 3:06 am #6803
The forum ‘WP Rich Snippets Plugin’ is closed to new topics and replies.