Skip to content

Instantly share code, notes, and snippets.

@naneri
Last active August 29, 2015 14:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save naneri/aa354d058d05424c9126 to your computer and use it in GitHub Desktop.
Save naneri/aa354d058d05424c9126 to your computer and use it in GitHub Desktop.
Facebook print likes list
<?php
header('Content-type: text/plain; charset=utf-8');
//declare the number of the post/photo in the $post_nmuber variable
$post_number = '';
$list = file_get_contents('http://graph.facebook.com/v1.0/' . $post_number . '/likes?pretty=1&limit=600&after=MTAwMDAyNTI4ODAyMDYx');
$array = json_decode($list);
foreach($array->data as $user){
echo $user->name . "\n";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment