views:

242

answers:

2

When posting a link to your facebook profile, users are presented with the option to choose a thumbnail to represent the link, as seen in the following example:

http://www.everyday.com.my/photo/2009/4/Add-Sushi-King-into-my-Facebook-profile.jpg (New users aren't allowed to embed images)

The thumbnails presented to the user are the different images contained on the page being shared / linked to.

Anyone have any ideas regarding what process Facebook is using to offer this feature? Specifically I would like to reproduce it using a combination of PHP/JQuery, and was hoping there might be an implementation out there already for me to build on.

Thanks!

A: 

Try this: http://www.thumbshots.org/

If that doesn't work out then maybe you can embed Alexa's site thumbnails.

Linus Sjögren
A: 

Another option is websnapr.com

You could just add something like this to your code:

var myurl = 'http://www.google.com';
var thumbnail = '<img src="http://images.websnapr.com/?url=' + myurl + '" alt="' + myurl + '">';

document.write(thumbnail);
fudgey
Just to Clarify - Facebook does not take a "screenshot" of the page, like ThumbShots. Instead, it allows for the selection of specific images which are contained within the page. Hence, I would think the process Facebook users is something along the lines of:1) Lookup page in background2) Crawl DOM object, pick out large images3) Create thumbnails of image4) Display thumbnails to userWhat I'm looking for is confirmation of my assumption, and even better an open-source example of this feature implemented.
HipHop-opatamus