Asked  8 Months ago    Answers:  5   Viewed   38 times

In facebook, when you share a link, a neat little preview is created with an image headline, and text excerpt. Here's an example..

Example Link

Does anyone know if there's any open-source code (pref. php & javascript/jquery) that can generate something like this? Or should I just write it myself..

Cheers!

 Answers

91

After a bit of Googling I found this for you.

It should take you through the steps on how to create something similar to Facebook share previews.

Wednesday, March 31, 2021
 
njai
answered 8 Months ago
14

I just use the Facebook login button - https://developers.facebook.com/docs/reference/plugins/login/

Once the user has used that to login (if they weren't already) and grant access to your app (site), the PHP-SDK should have no trouble using the Facebook session and APIs.

Update

I just tried this with the new version 3.0 PHP SDK and it is definitely not working. Found this on the developer blog

If you are using the JavaScript SDK for login in conjunction with the PHP SDK, you will want to wait for the JavaScript SDK upgrade (coming in 4 weeks). Version 3.0.0 of the PHP SDK won’t cooperate with the current JavaScript SDK due to the cookie format changing.

In other words, use the v2 PHP SDK until the JS SDK is updated.

Wednesday, March 31, 2021
 
Nickool
answered 8 Months ago
21

http://frankkoehl.com/2009/03/free-open-source-alternative-sharethis-addthis-addtoany/

The tl;dr version is that there is an opensource alternative (called iBegin Share). It is under an MIT license which gives you the right to:

deal in the Software without restriction, including without limitation the rights to use, copy, modify...

Saturday, May 29, 2021
 
TheTechnicalPaladin
answered 5 Months ago
95

It's a bug in the plugin

https://developers.facebook.com/bugs/604681079553717

Damn.. FB are slow on fixing!

Saturday, May 29, 2021
 
IvanH
answered 5 Months ago
68

I've found that BUSL works really well on Groovy files. It's standalone too, so you can use it from your text editor or whatever.

Saturday, September 18, 2021
 
Pwner
answered 1 Month ago
Only authorized users can answer the question. Please sign in first, or register a free account.
Not the answer you're looking for? Browse other questions tagged :
 
Share