Error When running get campaigns through url

9 views
Skip to first unread message

sz...@mymail.mines.edu

unread,
Jun 8, 2018, 11:43:37 AM6/8/18
to AdWords API and Google Ads API Forum
Hello, I have been able to successfully run getCampaigns.php locally to return my test campaigns. I have put the api on a web server for my website, but when I try to run getCampaigns through a url I run into the following error: 
Parse error: syntax error, unexpected T_CLASS, expecting T_STRING or T_VARIABLE or '$' in /home/gulliver/public_html/db/sean/googleads-php-lib/examples/AdWords/v201802/BasicOperations/GetCampaigns.php on line 44

My adsapi_php.ini file is completely filled out with the same information I used to run getCampaigns locally. Please let me know the best way to fix this error.

Sean

Bharani Cherukuri (AdWords API Team)

unread,
Jun 8, 2018, 4:46:56 PM6/8/18
to AdWords API and Google Ads API Forum
Hello Sean, 

Could you check the PHP version you are using? The new PHP client library requires PHP 5.5.9 and higher. If updating to PHP version 5.5.9 or above doesn't solve the issue, please post your question in the library's Github Issue Tracker since this is specific to the PHP client library. 

Regards,
Bharani, AdWords API Team
Reply all
Reply to author
Forward
0 new messages