如何获得谷歌+授权用户+1(如),事件和组列表或详细信息?

时间:2012-05-12 06:08:48

标签: php google-plus

我希望google plus授权users(individual) likes(+1)eventsfriendsuser加入Google群组详情或列表。

我在php(magento)中开发谷歌社交连接器。我已完成Google用户身份验证。

1 个答案:

答案 0 :(得分:2)

此get活动类似于facebook页面列表 你也可以获得特定活动评论列表和+ 1ed

  $optParams = array('maxResults' => 100);
  $activities = $plus->activities->listActivities('me', 'public', $optParams);
   $activityMarkup = '';

  foreach($activities['items'] as $activity) {
        $comments = $plus->comments->listComments($activity['id'],$optParams);
 foreach($comments['items'] as $comment) {
   print "<br />{$comment['id']}, {$comment['object']['content']}\n"; 
   echo "+1<br />";
   }
 $plusoners = $plus->people->listByActivity($activity['id'], "plusoners", $optParams);
foreach($plusoners['items'] as $person) {
  print "{$person['displayName']} +1'ed the post\n<br />";
}