How can I embed a facebook photo album with comments and tagging directly into a webpage?
I want to be able to embed a facebook photo album complete with comments and and photo tagging directly on a webpage. Basically I want it to look as close as possible to the way it does on facebook.开发者_运维技巧com.
So far the only solution I found is to just embed the pictures from the album without comments or photo tagging capabilities. Can anyone help point me in the right direction?
It would be neat to have this all wrapped up and ready to drop in, but I haven't found anything like that. You have to get all the info, and use your own css.
I use fql: http://developers.facebook.com/docs/reference/fql/ For instance (this is a lot more than I actually have ever used):
q0 = "SELECT aid,name,descripton FROM album WHERE owner="+theirID;
q1 = "SELECT pid,aid,src_small,caption,object_id FROM photo WHERE aid IN (SELECT aid FROM #q0)";
q2 = "SELECT fromid,text,id,username,likes FROM comment WHERE object_id IN (SELECT object_id FROM #q1)";
q3= "SELECT * FROM photo_tag WHERE pid IN (SELECT pid FROM #q1)";
FB.api( { method: 'fql.multiquery', queries: {"q0": q0,"q1":q1,"q2":q2,"q3":q3}}, function(re) {
// sort out the mess
// eg albumDescription = re[0].fql_result_set[item].description;
});
精彩评论