Skip to content

Latest commit

 

History

History
32 lines (19 loc) · 1.42 KB

File metadata and controls

32 lines (19 loc) · 1.42 KB

fetch facebook comments using php

Script to fetch comments of facebook post using PHP and cURL

for profile posts

GET ACCESS TOKEN

Go & create facebook app by clicking https://developers.facebook.com/apps/ then go to https://developers.facebook.com/tools/explorer/ and create access token by clicking on Get Token drop down & select Get User Access Token option & the modal will appear, from modal select user_posts and user_status from upper right top Copy the access token.

GET PROFILE NUMERIC ID

copy you profile link and get numeric id no of your profile by going to this website https://findmyfbid.com/ and copy your numeric profile id.

paste the credentials in profile.php and run the file, a text field and button will appear on screen enter post id and click on run, the table will appear with date, name, comment and link to visit comment. DONE

for page posts

GET ACCESS TOKEN

Go & create facebook app by clicking https://developers.facebook.com/apps/ then go to https://developers.facebook.com/tools/explorer/ and create access token by clicking on Get Token drop down & select page you want to fetch comments of post of. and copy access token.

paste the credentials in page.php and run the file, a text field and button will appear on screen enter post id and click on run, the table will appear with date, name, comment and link to visit comment. DONE

Contributors