File tree Expand file tree Collapse file tree 3 files changed +14
-11
lines changed Expand file tree Collapse file tree 3 files changed +14
-11
lines changed Original file line number Diff line number Diff line change 34
34
use Google \Analytics \Data \V1beta \BetaAnalyticsDataClient ;
35
35
use Google \Analytics \Data \V1beta \DateRange ;
36
36
use Google \Analytics \Data \V1beta \Dimension ;
37
- use Google \Analytics \Data \V1beta \Entity ;
38
37
use Google \Analytics \Data \V1beta \Metric ;
39
38
40
39
/**
62
61
'dimensions ' => [new Dimension (
63
62
[
64
63
'name ' => 'city ' ,
65
- ]),
64
+ ]
65
+ ),
66
66
],
67
67
'metrics ' => [new Metric (
68
68
[
69
69
'name ' => 'activeUsers ' ,
70
- ])
70
+ ]
71
+ )
71
72
]
72
73
]);
73
74
// [END analyticsdata_run_report]
79
80
foreach ($ response ->getRows () as $ row ) {
80
81
print $ row ->getDimensionValues ()[0 ]->getValue ()
81
82
. ' ' . $ row ->getMetricValues ()[0 ]->getValue () . PHP_EOL ;
82
- // [END analyticsdata_run_report_response]
83
+ // [END analyticsdata_run_report_response]
83
84
}
84
85
// [END analytics_data_quickstart]
Original file line number Diff line number Diff line change 35
35
use Google \Analytics \Data \V1beta \BetaAnalyticsDataClient ;
36
36
use Google \Analytics \Data \V1beta \DateRange ;
37
37
use Google \Analytics \Data \V1beta \Dimension ;
38
- use Google \Analytics \Data \V1beta \Entity ;
39
38
use Google \Analytics \Data \V1beta \Metric ;
40
39
41
40
/**
71
70
'dimensions ' => [new Dimension (
72
71
[
73
72
'name ' => 'city ' ,
74
- ]),
73
+ ]
74
+ ),
75
75
],
76
76
'metrics ' => [new Metric (
77
77
[
78
78
'name ' => 'activeUsers ' ,
79
- ])
79
+ ]
80
+ )
80
81
]
81
82
]);
82
83
// [END analyticsdata_json_credentials_run_report]
88
89
foreach ($ response ->getRows () as $ row ) {
89
90
print $ row ->getDimensionValues ()[0 ]->getValue ()
90
91
. ' ' . $ row ->getMetricValues ()[0 ]->getValue () . PHP_EOL ;
91
- // [END analyticsdata_json_credentials_run_report_response]
92
+ // [END analyticsdata_json_credentials_run_report_response]
92
93
}
93
94
94
95
// [END analytics_data_quickstart]
Original file line number Diff line number Diff line change 21
21
use Google \Analytics \Data \V1beta \BetaAnalyticsDataClient ;
22
22
use Google \Analytics \Data \V1beta \DateRange ;
23
23
use Google \Analytics \Data \V1beta \Dimension ;
24
- use Google \Analytics \Data \V1beta \Entity ;
25
24
use Google \Analytics \Data \V1beta \Metric ;
26
25
use Google \ApiCore \ApiException ;
27
26
use Google \Auth \OAuth2 ;
68
67
'dimensions ' => [new Dimension (
69
68
[
70
69
'name ' => 'city ' ,
71
- ]),
70
+ ]
71
+ ),
72
72
],
73
73
'metrics ' => [new Metric (
74
74
[
75
75
'name ' => 'activeUsers ' ,
76
- ])
76
+ ]
77
+ )
77
78
]
78
79
]);
79
80
You can’t perform that action at this time.
0 commit comments