By Sunny on Thursday, 30 November 2017
Posted in Technical Issues
Likes 0
Views 1.4K
Votes 0
Hi,

I've recently came across an issue with facebook URL shares.

I've kept og:image as the avatar of the user, so when anyone shares a url, the image accompanying should ideally be the user avatar of that page.

But facebook is not taking this avatar and inserting any random image on that page.

On investigating i found that Facebook requires minimum 200x200px image for picking up the og:image, if the image is below this size then it would pick a random image. (In my case an advertising banner on the is being pulled by Facebook!)

Easysocial by default converts images to 180x180 pixels avatars, so is their anyway we can increase this size to 250x250px.

And secondly can we purge and recreate avatars? (I've thousands of old users whose avatars are in 180x180px, ideally i would want them to be of above 200x200px)

Any help would be much appreciated.

regards
Sunny
Hey Sunny,

Hm, unfortunately that is not possible currently to change the size to 200x200 Perhaps you could post this under the feature request area and we'll try to change the square width to 200x200 . Not sure if this would affect the file size for users with small disk space though
·
Friday, 01 December 2017 00:31
·
0 Likes
·
0 Votes
·
0 Comments
·
Also, re-generating avatars are tricky because if your site has 100,000 users, it's going to take ages
·
Friday, 01 December 2017 00:35
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Mark,

I understand the file size bottleneck, but i do believe the increment in file size would not be much. But yes the overall disc requirement would be proportional to the number of users.

while checking i found the following code in the file ...\administrator\components\com_easysocial\constants.php
on Line 72

define('SOCIAL_AVATAR_LARGE_WIDTH', 180);
define('SOCIAL_AVATAR_SQUARE_LARGE_WIDTH', 220);
define('SOCIAL_AVATAR_SQUARE_LARGE_HEIGHT', 220);


Can i change it to below code to achieve the minimum width of 220 pixel?

define('SOCIAL_AVATAR_LARGE_WIDTH', 220);
define('SOCIAL_AVATAR_SQUARE_LARGE_WIDTH', 250);
define('SOCIAL_AVATAR_SQUARE_LARGE_HEIGHT', 250);


Can you please point me disadvantage or pitfall above hack would cause.

regards
Sunny
·
Friday, 01 December 2017 12:35
·
0 Likes
·
0 Votes
·
0 Comments
·
Hey Sunny,

I am really sorry for the delay of this reply as it is actually a public day off for us here. You could change it here but this would not affect existing users. It would only be applied to new users on the site.
·
Friday, 01 December 2017 14:47
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks Mark for the confirmation, Sorry for disturbing your holiday.. enjoy the rest of it!
regards
·
Friday, 01 December 2017 18:19
·
0 Likes
·
0 Votes
·
0 Comments
·
No problem Sunny Have a great weekend ahead!
·
Friday, 01 December 2017 22:41
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post