1

だから私はこのコードを持っています

$yt->setMajorProtocolVersion(2);

$activityFeed = $yt->getActivityForUser("google");
printActivityFeed($activityFeed);

function printActivityFeed($activityFeed) {
  foreach($activityFeed as $activityEntry) {
    $author = $activityEntry->getAuthorName();
    $gr = $activityEntry->getRating();
  }
}

$grコメントが高く評価されたり低く評価されたりしても、常にnull存在する/存在しないのはなぜですか?

4

1 に答える 1

0

Your PHP code translates into this API call:

https://gdata.youtube.com/feeds/api/users/google/events?v=2&prettyprint=true&key=AI39si6ZOCQQ0oBM_xkRpAO_sbowfEDoXQ10opTm62ZFj_2qjJtCI6GXGHCCz2bD2XObbV6uNPUx1EdbFXhwgN9-baWcKASXJg

If you take a look at the activities in that feed, none of them have to do with rating a comment. It stands to reason that the YouTube username "Google" hasn't rated any comments recently.

于 2012-12-12T17:37:01.233 に答える