Page 1 of 1

thumbnail on Facebook etc.

Posted: 06 Aug 2013 20:31
by bobnotts
Evening all. Is there any scope to alter the thumbnail for Facebook and the like? (See attached)

Re: thumbnail on Facebook etc.

Posted: 07 Aug 2013 15:47
by choralia
I don't use Facebook, however I googled a little bit and found (see this link for example) that, when posting a link, Facebook should normally propose multiple options (Auto-Detected by Facebook; Auto-Detected from Item Content; Manual; Disabled) to select the most appropriate thumbnail associated to the link. So, I think that you should use such features to select the most appropriate thumbnail (e.g., the CPDL logo).

On our side we may possibly help the auto-detection process by adding some Metadata to the html header of all wiki pages, so that auto-detection will most likely select our preferred thumbnail. I think that this can be configured somehow using MediaWiki extensions or something like that, but I'm not sure.

Max

Re: thumbnail on Facebook etc.

Posted: 08 Aug 2013 06:30
by bobnotts
Thanks for investigating, Max. In this case, because I posted the link from a mobile device, I didn't get to choose the thumbnail that Facebook displays for the link, though I understand this is possible when using the site from a desktop. I believe we can put something in our website code to request that Facebook and other sites use a particular thumbnail so if we can set that to our logo, that'd be great, though I'm afraid I've no idea how!

Re: thumbnail on Facebook etc.

Posted: 08 Aug 2013 15:55
by carlos
Rob, I added yesterday a hidden logo inside one of the left menu boxes, to see if it would be found by facebook, but unfortunately that didn't happen. I'm going to change the image to 1x1 pixel size (but this time visible) and see what happens (will have to wait until tomorrow, so that the changes are mirrored).

Re: thumbnail on Facebook etc.

Posted: 09 Aug 2013 19:43
by bobnotts
OK, thanks Carlos

Re: thumbnail on Facebook etc.

Posted: 28 Aug 2013 19:01
by uptoncp
It so happens that I posted a link on Facebook about half an hour before looking at this thread; I can confirm that the NotePerfect ad is still the default selection.

Re: thumbnail on Facebook etc.

Posted: 28 Aug 2013 23:18
by carlos
Yes, unfortunately the various tests realized by me didn't work out as expected and the wrong icon is still being displayed.

Re: thumbnail on Facebook etc.

Posted: 06 Sep 2013 16:47
by choralia
This MediaWiki extension looks interesting to possibly solve this problem.

Max

Re: thumbnail on Facebook etc.

Posted: 07 Sep 2013 15:51
by choralia
choralia wrote:This MediaWiki extension looks interesting to possibly solve this problem.
I changed my mind. Documentation was rather poor, and I think that it was only designed to provide page-by-page metadata, rather than to provide a default set of metadata for all pages of Choralwiki.

So, I developed a very simple extension that simply adds the same metadata to the HTML header of all pages:

Code: Select all

<meta property="og:image" content="http://www.cpdl.org/wiki/images/5/5f/Toplogo2.gif" />
The inspection of the HTML raw code of the pages as well as the Facebook debug tool seem to confirm that it works. I had to use a larger image with respect to the one uploaded by Carlos as the debug tool stated that images smaller than 200 x 200 pixels are not considered by Facebook.

Please note: the extension is currently installed on the contributor wiki only (www.cpdl.org). It will propagate to the visitor wikis (www0, www1, www2, www3) tomorrow. Furthermore, cached pages without the additional metadata may still be shown for some time. So, the effect might not be immediate.

Max

Re: thumbnail on Facebook etc.

Posted: 08 Sep 2013 04:29
by carlos
Just checked and it works fine, thanks Max!

I noticed that the thumbnail was being cropped when displayed inside facebook, so I uploaded a new version in square format, 200x200, ok?

Re: thumbnail on Facebook etc.

Posted: 08 Sep 2013 07:53
by choralia
carlos wrote:I uploaded a new version in square format, 200x200, ok?
Yes, of course! Thank you for checking and improving, Carlos.

Max