The google-api-php-client library has no method setClientRedirectUri() in apiClient. The correct method is called setRedirectUri():$client = new apiClient();$client->setApplicationName('Hello Analytics API Sample');// Visit //code.google.com/apis/console?api=analytics to generate your// client id, client secret, and to register your redirect uri.$client->setClientId('insert_your_oauth2_client_id');$client->setClientSecret('insert_your_oauth2_client_secret');$client->setRedirectUri('insert_your_oauth2_redirect_uri');$client->setDeveloperKey('insert_your_developer_key');$client->setScopes(array('https://www.googleapis.com/auth/analytics.readonly')); 这篇关于Google Analytics PHP API重定向URI的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
08-12 23:00