Created
September 11, 2013 08:33
-
-
Save sfelde/6520832 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'facebook-php-sdk/src/facebook.php'; | |
4 | |
5 $facebook = new Facebook(array( | |
6 'appId' => '82178x12503x4x', | |
7 'secret' => 'f4dad06ae9xxxxxxxx', | |
8 )); | |
9 | |
10 $posts = $facebook->api('/nickname/feed?limit=20'); | |
11 | |
12 foreach($posts['data'] as $post){ | |
13 if (!empty($post['message'])){ | |
14 $messages['data'][] = $post; | |
15 } | |
16 } | |
17 | |
18 echo json_encode($messages) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment