I have a site with a bunch of links, the page is also connected to facebook (facebook connect)开发者_如何学C and you can "like" the links. I wonder if there is a way to sort on the "most liked" link? The links are stored in my database and of course the liking is stored by Facebook...
I'm not too familiar with liking links, but perhaps you can query the link_stat
table. http://developers.facebook.com/docs/reference/fql/link_stat
Here is an even easier method to get likes. It doesn't require that you are logged in to Facebook. I have also made an example of how you can sort them. In PHP though.. :-/ http://www.sundh.com/blog/2010/11/get-likes-on-urls-from-facebook/
- You should retrieve your links' Likes Count from facebook by sending url's or by FQL, etc
- Store "liking" count in your urls table
- Sort your links table ORDER BY -linkcountfield- DESC
精彩评论