Yawning Milk Yawning Milk -4 years ago 217
PHP Question

Google AdWords and Laravel 5.2

So I've got a project in Laravel 5.2, and I have to use Google Ads here. How should I request necessary files and libraries in my controllers?

For example, I have

/var/www/project/app/controllers/Controller.php
, and all Google provided src, examples etc. are stored in
/var/www/project/public/ads
folder. Then, from my Controller.php I want to get list of campaigns available in my account.

What should I write in the head of the controller? Some
use
or
require_once
? For now I have only these two:

require_once public_path('ads') . '/init.php';
require_once ADWORDS_UTIL_VERSION_PATH . '/ReportUtils.php';

Answer Source

Welp it looks like those are included simply like use AdWordsUser, use Selector and so on. That was easy.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download