2012-03-31 58 views

回答

0

獲取commentsbox_countlink_stat FQL表,example

select commentsbox_count from link_stat where url = 'http://techcrunch.com/2012/03/31/dramacrunch/' 

PHP例子:

$query = urlencode("select commentsbox_count from link_stat where url = 'http://techcrunch.com/2012/03/31/dramacrunch/'"); 
$response = json_decode(file_get_contents("https://graph.facebook.com/fql?q=$query"), TRUE); 
if(!empty($response['data'][0]['commentsbox_count'])) { 
    echo $response['data'][0]['commentsbox_count'] . " comments were found!"; 
} 
+1

完美。謝謝 – 2012-04-01 06:18:39