For Facebook Integration
Something I put together for testing the graph ..
function fetchData($user)
{
if(!empty($user))
{
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://graph.facebook.com/".$user);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_REFERER, "http://www.jpmalloy.com"); // change to your URL
$body = curl_exec($ch); // json string
curl_close($ch);
$data = json_decode($body, true);
return $data;
}
}
$user = ''; // Facebook username
$data = fetchData($user);
echo "https://graph.facebook.com/".$data['id']."/picture?type=large";
-
kingjpm -
Thanks
SignatureRogueDen.com{{ DiscussionBoard.errors[9287121].message }} -