PluginProbe ʕ •ᴥ•ʔ
ShareThis Dashboard for Google Analytics / 2.1.2
ShareThis Dashboard for Google Analytics v2.1.2
3.3.2 trunk 1.0.7 2.0.0 2.0.1 2.0.2 2.0.3 2.0.4 2.0.5 2.1 2.1.2 2.1.3 2.1.4 2.1.5 2.2.5 2.3.5 2.3.6 2.3.7 2.3.8 2.4.0 2.4.1 2.5.0 2.5.1 2.5.2 2.5.3 2.5.4 2.5.5 3.0.0 3.1.0 3.1.1 3.1.2 3.1.3 3.1.4 3.1.5 3.1.6 3.1.7 3.2.0 3.2.1 3.2.2 3.2.3 3.2.4 3.3.0 3.3.1
googleanalytics / view / stats.php
googleanalytics / view Last commit date
ga_accounts_selector.php 9 years ago ga_auth_button.php 9 years ago ga_code.php 9 years ago ga_dashboard_widget.php 9 years ago ga_debug_modal.php 9 years ago ga_googleanalytics_loader.php 9 years ago ga_notice.php 9 years ago ga_oauth_notice.php 9 years ago ga_wp_notice.php 9 years ago page.php 9 years ago statistics.php 9 years ago stats.php 9 years ago trending.php 9 years ago
stats.php
128 lines
1 <div class="wrap ga-wrap" id="ga-stats-container">
2 <?php if ( ! empty( $chart ) ) : ?>
3 <div class="ga-panel ga-panel-default">
4 <div class="ga-panel-heading"><strong><?php _e( "Pageviews - Last 7 days vs previous 7 days" ) ?></strong></div>
5 <div class="ga-panel-body ga-chart">
6 <div id="chart_div" style="width: 100%;"></div>
7 <div class="ga-loader-wrapper stats-page">
8 <div class="ga-loader stats-page-loader"></div>
9 </div>
10 </div>
11 </div>
12 <?php endif; ?>
13
14 <?php if ( ! empty( $boxes ) ) : ?>
15 <div class="ga-panel ga-panel-default">
16 <div class="ga-panel-heading"><strong><?php _e( "Comparison - Last 7 days vs previous 7 days" ) ?></strong>
17 </div>
18 <div class="ga-panel-body">
19 <div class="ga-row">
20 <?php foreach ( $boxes as $box ) : ?>
21 <div class="ga-box">
22 <div class="ga-panel ga-panel-default">
23 <div class="ga-panel-body ga-box-centered">
24 <div class="ga-box-label"><?php echo $box['label'] ?></div>
25 <div class="ga-box-diff"
26 style="color: <?php echo $box['color'] ?>;"><?php echo Ga_Helper::format_percent( $box['diff'] ); ?></div>
27 <div class="ga-box-comparison"><?php echo $box['comparison'] ?></div>
28 </div>
29 </div>
30 </div>
31 <?php endforeach; ?>
32 </div>
33 </div>
34 </div>
35 <?php endif; ?>
36
37 <?php if ( ! empty( $sources ) ) : ?>
38 <div class="ga-panel ga-panel-default">
39 <div class="ga-panel-heading"><strong><?php _e( "Top 5 Traffic Sources for the past 7 days" ) ?></strong>
40 </div>
41 <div class="ga-panel-body">
42
43 <div id="table-container">
44 <table class="ga-table">
45 <tr>
46 <td colspan="2">
47 </td>
48 <th style="text-align: right;">
49 <?php _e( 'Pageviews' ); ?>
50 </th>
51 <th style="text-align: right;">
52 <?php echo '%'; ?>
53 </th>
54 </tr>
55 <tr>
56 <td colspan="2"></td>
57 <td class="ga-col-pageviews" style="text-align: right">
58 <div style="font-size: 16px;"><?php echo $sources['total'] ?></div>
59 <div style="color: grey; font-size: 10px;">% of
60 Total: <?php echo Ga_Helper::format_percent( ( ! empty( $sources['total'] ) ) ? number_format( $sources['sum'] / $sources['total'] * 100,
61 2, '.', ' ' ) : 100 );
62 ?>
63 (<?php echo $sources['sum'] ?>)
64 </div>
65 </td>
66 <td class="ga-col-progressbar" style="text-align: right">
67 <div style="font-size: 16px;"><?php echo $sources['total'] ?></div>
68 <div style="color: grey; font-size: 10px;">% of
69 Total: <?php echo Ga_Helper::format_percent( ( ! empty( $sources['total'] ) ) ? number_format( $sources['sum'] / $sources['total'] * 100,
70 2, '.', ' ' ) : 100 );
71 ?>
72 (<?php echo $sources['sum'] ?>)
73 </div>
74 </td>
75 </tr>
76 <?php foreach ( $sources['rows'] as $key => $source ): ?>
77 <tr>
78 <td style="width: 5%;text-align: right"><?php echo $key ?>.</td>
79 <td class="ga-col-name">
80 <?php if ( $source['name'] != '(direct) / (none)' ) : ?>
81 <a class="ga-source-name" href="<?php echo $source['url'] ?>"
82 target="_blank"><?php echo $source['name'] ?></a>
83 <?php else: ?>
84 <?php echo $source['name'] ?>
85 <?php endif; ?>
86 </td>
87 <td style="text-align: right"><?php echo $source['number'] ?></td>
88 <td>
89 <div class="progress">
90 <div class="progress-bar" role="progressbar"
91 aria-valuenow="<?php echo $source['percent'] ?>" aria-valuemin="0"
92 aria-valuemax="100"
93 style="width: <?php echo $source['percent'] ?>%;"></div>
94 <span style="margin-left: 10px;"><?php echo Ga_Helper::format_percent( $source['percent'] ); ?></span>
95 </div>
96 </td>
97 </tr>
98 <?php endforeach; ?>
99 </table>
100 </div>
101 </div>
102 </div>
103 <?php endif; ?>
104
105 <?php if ( ! empty( $chart ) ) : ?>
106 <script type="text/javascript">
107
108 ga_charts.init(function () {
109
110 var data = new google.visualization.DataTable();
111 data.addColumn('string', 'Day');
112 data.addColumn('number', '<?php echo $labels['thisWeek'] ?>');
113 data.addColumn({type: 'string', role: 'tooltip', 'p': {'html': true}});
114 data.addColumn('number', '<?php echo $labels['lastWeek'] ?>');
115 data.addColumn({type: 'string', role: 'tooltip', 'p': {'html': true}});
116
117 <?php foreach ( $chart as $row ) : ?>
118 data.addRow(['<?php echo $row['day'] ?>', <?php echo $row['current'] ?>, ga_charts.createTooltip('<?php echo $row['day'] ?>', '<?php echo $row['current'] ?>'), <?php echo $row['previous'] ?>, ga_charts.createTooltip('<?php echo $row['previous-day'] ?>', '<?php echo $row['previous'] ?>')]);
119 <?php endforeach; ?>
120 ga_charts.events(data);
121 ga_charts.drawChart(data);
122 ga_loader.hide();
123 }
124 );
125 </script>
126 <?php endif; ?>
127 </div>
128