Aug 05
This code will help you extract urls from google analytics account with analytics API by Felix Geisendörfer
// Start Code for getting the URLs
$pages = $this->Analytics->report(array(
‘profile’ => ‘PROFILE_NAME’,
‘report’ => ‘TopContent’,
‘trows’ => ‘500′
));
foreach ($pages[’AnalyticsReport’][’Report’][’Table’][’Row’] as $pages_individual):
$pages_urls[$pages_individual[’Key’][’#text’]] = $pages_individual[’Key’][’#text’];
endforeach;
$this->set(’pages_urls’,$pages_urls);
//End Code for getting URLs
September 18th, 2008 at 7:31 pm
Just a quick reminder that this uses cakephp
September 24th, 2008 at 10:04 pm
Thanks for the code!