0

I know that there are many questions about it, but it is not really what I want.

I have a page with multiple posts on it. Each post has its own comments count. It was simple to get comments count of each post when I was using native website commenting system. Now I want to use Facebook comments API. But there is a problem, how to get comments count of 20-30 posts which are loading dynamicly.

I have few ideas about that:

1) Grab all urls of that 20-30 posts. Make an async request to FB opengraph to get comments count. Parse DOM and change count values.

But this can be slow and don't know if there is an ability to get count for a bunch of urls

2) Prepare CRON method to grab comments count for all posts. And save info to DB.

Not sure, how to do that. But still a variant =)

Any ideas about that? Would be nice to hear your variants to solve this issue!

John
  • 1
  • 2

1 Answers1

0

There are already multiple answers to this at SO I think. Have a look at How to get most liked, commented and shared posts from Facebook's API to get an idea of how to pull the data on all Page feed entries...

Community
  • 1
  • 1
Tobi
  • 31,405
  • 8
  • 58
  • 90
  • This answer is good for page with one post, but what about page with multiple posts with their own url and comments? – John Jun 23 '14 at 09:21