WP-Matomo (WP-Piwik) - Version 0.9.9.8

Version Description

  • Feature: Per post stats (shown at the edit post page)
  • Feature: Track RSS views using a measurement pixel
Download this release

Release Info

Developer Braekling
Plugin Icon 128x128 WP-Matomo (WP-Piwik)
Version 0.9.9.8
Comparing to
See all releases

Code changes from version 0.9.9.7 to 0.9.9.8

classes/WP_Piwik_MetaBox_PerPost_Stats.php ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ require_once('WP_Piwik_Template.php');
4
+
5
+ class WP_Piwik_MetaBox_PerPost_Stats extends WP_Piwik_Template {
6
+
7
+ function addMetabox() {
8
+ add_meta_box(
9
+ 'wp-piwik_post_perpoststats',
10
+ __('Piwik Statistics (last 30 days)', 'wp-piwik'),
11
+ array(&$this, 'showStats'),
12
+ 'post',
13
+ 'side',
14
+ 'default'
15
+ );
16
+ }
17
+
18
+ function showStats() {
19
+ global $post;
20
+ $postURL = get_permalink($post->ID);
21
+ $range = $this->getRangeLast30();
22
+ self::$logger->log('Load per post statistics: '.$postURL);
23
+ $data = self::$wpPiwik->callPiwikAPI('Actions.getPageUrl', 'range', $range, null, false, false, 'PHP', $postURL, false);
24
+ if (!isset($data[0])) return;
25
+ echo '<table>';
26
+ $this->tabRow(__('Visitors', 'wp-piwik').':',$data[0]['nb_visits']);
27
+ $this->tabRow(__('Unique visitors', 'wp-piwik').':', $data[0]['sum_daily_nb_uniq_visitors']);
28
+ $this->tabRow(__('Page views', 'wp-piwik').':', $data[0]['nb_hits']);
29
+ $this->tabRow(__('Time/visit', 'wp-piwik').':', $data[0]['avg_time_on_page']);
30
+ $this->tabRow(__('Bounce count', 'wp-piwik').':', $this->output($data[0], 'entry_bounce_count', 0).' ('.$data[0]['bounce_rate'].')');
31
+ $this->tabRow(__('Exit count', 'wp-piwik').':', $this->output($data[0], 'exit_nb_visits', 0).' ('.$data[0]['exit_rate'].')');
32
+ if (isset($data[0]['avg_time_generation']))
33
+ $this->tabRow(__('Avg. generation time', 'wp-piwik').':', $data[0]['avg_time_generation']);
34
+ echo '</table>';
35
+ }
36
+
37
+ }
classes/WP_Piwik_Settings.php CHANGED
@@ -31,6 +31,11 @@
31
  'track_post' => false,
32
  'track_proxy' => false,
33
  'track_admin' => false,
 
 
 
 
 
34
  'track_cdnurlssl' => '',
35
  'track_noscript' => false,
36
  'track_nojavascript' => false,
31
  'track_post' => false,
32
  'track_proxy' => false,
33
  'track_admin' => false,
34
+ 'track_feed' => false,
35
+ 'track_feed_goal' => '',
36
+ 'track_feed_revenue' => '',
37
+ 'track_feed_campaign' => 'feed',
38
+ 'track_feed_addcampaign' => 'false',
39
  'track_cdnurlssl' => '',
40
  'track_noscript' => false,
41
  'track_nojavascript' => false,
classes/WP_Piwik_Template.php ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class WP_Piwik_Template {
4
+
5
+ public static $logger, $settings, $wpPiwik;
6
+
7
+ public function __construct($config) {
8
+ self::$logger = $config['logger'];
9
+ self::$settings = $config['settings'];
10
+ self::$wpPiwik = $config['wp_piwik'];
11
+ }
12
+
13
+ public function output($array, $key, $default = '') {
14
+ if (isset($array[$key]))
15
+ return $array[$key];
16
+ else
17
+ return $default;
18
+ }
19
+
20
+ public function tabRow($name, $value) {
21
+ echo '<tr><td>'.$name.'</td><td>'.$value.'</td></tr>';
22
+ }
23
+
24
+ public function getRangeLast30() {
25
+ $diff = (self::$settings->getGlobalOption('default_date') == 'yesterday') ? -86400 : 0;
26
+ $end = time() + $diff;
27
+ $start = time() - 2592000 + $diff;
28
+ return date('Y-m-d', $start).','.date('Y-m-d', $end);
29
+
30
+ }
31
+
32
+ }
languages/wp-piwik-de_DE.mo CHANGED
Binary file
languages/wp-piwik-de_DE.po CHANGED
@@ -686,4 +686,28 @@ msgid "Cache API calls, which not contain today's values, for a week"
686
  msgstr "Cache alle API-Aufrufe, die keine heutigen Daten enthalten, f&uuml;r eine Woche"
687
 
688
  msgid "Enable cache"
689
- msgstr "Cache einschalten"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
686
  msgstr "Cache alle API-Aufrufe, die keine heutigen Daten enthalten, f&uuml;r eine Woche"
687
 
688
  msgid "Enable cache"
689
+ msgstr "Cache einschalten"
690
+
691
+ msgid "This will add Piwik campaign parameters to the RSS feed links."
692
+ msgstr "Dadurch werden Piwik Kampagnen-Parameter an die Links des RSS-Feeds angehangen."
693
+
694
+ msgid "Campaign"
695
+ msgstr "Kampagne"
696
+
697
+ msgid "Keyword: post name."
698
+ msgstr "Schl&uuml;sselwort: Name des Beitrags."
699
+
700
+ msgid "Enable to track posts in feeds via tracking pixel."
701
+ msgstr "Aktivieren, um Beir&auml;ge im Feed via Tracking-Pixel zu z&auml;hlen."
702
+
703
+ msgid "Enable to track users on admin pages (remember to configure the tracking filter appropriately)."
704
+ msgstr "Aktivieren, um Nutzer auf Admin-Seiten zu z&auml;hlen (bitte den Tracking Filter entsprechend konfigurieren)."
705
+
706
+ msgid "Track RSS feed links as campaign"
707
+ msgstr "Links in RSS-Feeds als Kampagne tracken"
708
+
709
+ msgid "Show stats about single posts at the post edit admin page."
710
+ msgstr "Zeige Statistiken zu einzelnen Beitr&auml;gen auf der Bearbeiten-Seite."
711
+
712
+ msgid "Show per post stats"
713
+ msgstr "Zeige Beitrags-Statistiken"
languages/wp-piwik-zh_CN.mo ADDED
Binary file
languages/wp-piwik-zh_CN.po ADDED
@@ -0,0 +1,861 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: WP-Piwik\n"
4
+ "POT-Creation-Date: 2013-06-14 17:12+0800\n"
5
+ "PO-Revision-Date: 2013-06-14 22:37+0800\n"
6
+ "Last-Translator: mogita <chrisprc@gmail.com>\n"
7
+ "Language-Team: mogita <chrisprc@gmail.com>\n"
8
+ "Language: zh_CN\n"
9
+ "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=UTF-8\n"
11
+ "Content-Transfer-Encoding: 8bit\n"
12
+ "X-Generator: Poedit 1.5.5\n"
13
+ "X-Poedit-KeywordsList: _;gettext;gettext_noop;_e;__\n"
14
+ "X-Poedit-Basepath: .\n"
15
+ "X-Poedit-SearchPath-0: ..\n"
16
+ "X-Poedit-SearchPath-1: ../cache\n"
17
+ "X-Poedit-SearchPath-2: ../classes\n"
18
+ "X-Poedit-SearchPath-3: ../dashboard\n"
19
+ "X-Poedit-SearchPath-4: ../debug\n"
20
+ "X-Poedit-SearchPath-5: ../logs\n"
21
+ "X-Poedit-SearchPath-6: ../settings\n"
22
+ "X-Poedit-SearchPath-7: ../shortcodes\n"
23
+ "X-Poedit-SearchPath-8: ../update\n"
24
+
25
+ #: ../wp-piwik.php:197
26
+ msgid "installed"
27
+ msgstr "已安装"
28
+
29
+ #: ../wp-piwik.php:198
30
+ msgid "Next you should connect to Piwik"
31
+ msgstr "接下来,请连接到 Piwik"
32
+
33
+ #: ../wp-piwik.php:198
34
+ msgid "Please validate your configuration"
35
+ msgstr "请验证你的配置"
36
+
37
+ #: ../wp-piwik.php:199 ../wp-piwik.php:597 ../wp-piwik.php:1227
38
+ msgid "Settings"
39
+ msgstr "设置"
40
+
41
+ #: ../wp-piwik.php:200
42
+ msgid "Important"
43
+ msgstr "重要"
44
+
45
+ #: ../wp-piwik.php:328
46
+ msgid "Piwik Custom Variables"
47
+ msgstr "Piwik 自定义变量"
48
+
49
+ #: ../wp-piwik.php:342
50
+ msgid "Name"
51
+ msgstr "名称"
52
+
53
+ #: ../wp-piwik.php:342
54
+ msgid "Value"
55
+ msgstr "值"
56
+
57
+ #: ../wp-piwik.php:351
58
+ msgid "Set custom variables for a page view"
59
+ msgstr "为页面浏览量(PV)设置自定义变量"
60
+
61
+ #: ../wp-piwik.php:351
62
+ msgid "More information"
63
+ msgstr "更多信息"
64
+
65
+ #: ../wp-piwik.php:396 ../wp-piwik.php:437
66
+ msgid "Piwik Statistics"
67
+ msgstr "Piwik 统计"
68
+
69
+ #: ../wp-piwik.php:555 ../wp-piwik.php:974 ../dashboard/overview.php:56
70
+ #: ../shortcodes/overview.php:38
71
+ msgid "Visitors"
72
+ msgstr "访客"
73
+
74
+ #: ../wp-piwik.php:575 ../wp-piwik.php:965 ../dashboard/seo.php:20
75
+ msgid "SEO"
76
+ msgstr "SEO"
77
+
78
+ #: ../wp-piwik.php:723
79
+ msgid "Could not resolve"
80
+ msgstr "无法解析"
81
+
82
+ #: ../wp-piwik.php:723
83
+ msgid "realpath() returns false"
84
+ msgstr "realpath() 返回 false"
85
+
86
+ #: ../wp-piwik.php:964 ../dashboard/overview.php:23
87
+ #: ../shortcodes/overview.php:11
88
+ msgid "Overview"
89
+ msgstr "概览"
90
+
91
+ #: ../wp-piwik.php:966 ../dashboard/pages.php:13
92
+ msgid "Pages"
93
+ msgstr "页面"
94
+
95
+ #: ../wp-piwik.php:967 ../dashboard/keywords.php:12
96
+ msgid "Keywords"
97
+ msgstr "关键词"
98
+
99
+ #: ../wp-piwik.php:968 ../dashboard/websites.php:12
100
+ msgid "Websites"
101
+ msgstr "站点"
102
+
103
+ #: ../wp-piwik.php:969 ../dashboard/plugins.php:12 ../dashboard/plugins.php:33
104
+ msgid "Plugins"
105
+ msgstr "插件"
106
+
107
+ #: ../wp-piwik.php:970 ../dashboard/search.php:12
108
+ msgid "Site Search Keywords"
109
+ msgstr "站内搜索关键词"
110
+
111
+ #: ../wp-piwik.php:971 ../dashboard/noresult.php:12
112
+ msgid "Site Search without Results"
113
+ msgstr "未查找到结果的站内搜索"
114
+
115
+ #: ../wp-piwik.php:975 ../dashboard/browserdetails.php:39
116
+ #: ../dashboard/browsers.php:13 ../dashboard/browsers.php:40
117
+ msgid "Browser"
118
+ msgstr "浏览器"
119
+
120
+ #: ../wp-piwik.php:976 ../dashboard/browserdetails.php:12
121
+ msgid "Browser Details"
122
+ msgstr "浏览器细节"
123
+
124
+ #: ../wp-piwik.php:977 ../dashboard/screens.php:12 ../dashboard/screens.php:39
125
+ msgid "Resolution"
126
+ msgstr "分辨率"
127
+
128
+ #: ../wp-piwik.php:978 ../dashboard/systems.php:12 ../dashboard/systems.php:40
129
+ msgid "Operating System"
130
+ msgstr "操作系统"
131
+
132
+ #: ../wp-piwik.php:1050 ../wp-piwik.php:1124
133
+ msgid "Statistics"
134
+ msgstr "统计数据"
135
+
136
+ #: ../wp-piwik.php:1060
137
+ msgid "Currently shown stats:"
138
+ msgstr "目前展示的统计:"
139
+
140
+ #: ../wp-piwik.php:1107
141
+ msgid "Cheatin&#8217; uh?"
142
+ msgstr "呃,打开的方式不对吧?"
143
+
144
+ #: ../wp-piwik.php:1121
145
+ msgid "Home"
146
+ msgstr "首页"
147
+
148
+ #: ../wp-piwik.php:1122 ../wp-piwik.php:1128
149
+ msgid "Piwik Settings"
150
+ msgstr "Piwik 设置"
151
+
152
+ #: ../wp-piwik.php:1123
153
+ msgid "Tracking"
154
+ msgstr "跟踪"
155
+
156
+ #: ../wp-piwik.php:1125 ../wp-piwik.php:1129 ../wp-piwik.php:1286
157
+ msgid "Support"
158
+ msgstr "支持"
159
+
160
+ #: ../wp-piwik.php:1126 ../wp-piwik.php:1130
161
+ msgid "Credits"
162
+ msgstr "荣誉榜"
163
+
164
+ #: ../wp-piwik.php:1225
165
+ msgid "Changes saved"
166
+ msgstr "变更已保存"
167
+
168
+ #: ../wp-piwik.php:1233
169
+ msgid "Donate"
170
+ msgstr "捐赠"
171
+
172
+ #: ../wp-piwik.php:1234
173
+ msgid "If you like WP-Piwik, you can support its development by a donation:"
174
+ msgstr "如果你喜欢 WP-Piwik,可以考虑捐赠来支持它的开发:"
175
+
176
+ #: ../wp-piwik.php:1250
177
+ msgid "My Amazon.de wishlist"
178
+ msgstr "我的 Amazon.de 愿望单"
179
+
180
+ #: ../wp-piwik.php:1253 ../settings/support.php:8
181
+ msgid "Please don't forget to vote the compatibility at the"
182
+ msgstr "请记得提交兼容性投票,地址在"
183
+
184
+ #: ../wp-piwik.php:1268
185
+ msgid "Save settings"
186
+ msgstr "保存设置"
187
+
188
+ #: ../wp-piwik.php:1286
189
+ msgid "An error occured"
190
+ msgstr "出错了"
191
+
192
+ #: ../dashboard/browserdetails.php:16 ../dashboard/browsers.php:17
193
+ #: ../dashboard/keywords.php:14 ../dashboard/noresult.php:14
194
+ #: ../dashboard/overview.php:26 ../dashboard/pages.php:16
195
+ #: ../dashboard/plugins.php:26 ../dashboard/screens.php:16
196
+ #: ../dashboard/search.php:14 ../dashboard/seo.php:17
197
+ #: ../dashboard/systems.php:16 ../dashboard/visitors.php:26
198
+ #: ../dashboard/websites.php:15
199
+ msgid "Piwik error"
200
+ msgstr "Piwik 错误"
201
+
202
+ #: ../dashboard/browserdetails.php:25 ../dashboard/browsers.php:26
203
+ #: ../dashboard/pages.php:45 ../dashboard/screens.php:25
204
+ #: ../dashboard/systems.php:25
205
+ msgid "Others"
206
+ msgstr "其他"
207
+
208
+ #: ../dashboard/browserdetails.php:40 ../dashboard/browsers.php:41
209
+ #: ../dashboard/keywords.php:19 ../dashboard/pages.php:24
210
+ #: ../dashboard/screens.php:40 ../dashboard/systems.php:41
211
+ #: ../dashboard/visitors.php:58 ../dashboard/websites.php:22
212
+ msgid "Unique"
213
+ msgstr "独立访客"
214
+
215
+ #: ../dashboard/browserdetails.php:41 ../dashboard/browsers.php:42
216
+ #: ../dashboard/plugins.php:35 ../dashboard/screens.php:41
217
+ #: ../dashboard/systems.php:42
218
+ msgid "Percent"
219
+ msgstr "百分比"
220
+
221
+ #: ../dashboard/browserdetails.php:55 ../dashboard/browsers.php:56
222
+ #: ../dashboard/keywords.php:25 ../dashboard/noresult.php:25
223
+ #: ../dashboard/pages.php:43 ../dashboard/plugins.php:51
224
+ #: ../dashboard/screens.php:55 ../dashboard/search.php:25
225
+ #: ../dashboard/systems.php:56 ../dashboard/websites.php:29
226
+ msgid "No data available."
227
+ msgstr "目前无数据"
228
+
229
+ #: ../dashboard/keywords.php:19 ../dashboard/noresult.php:19
230
+ #: ../dashboard/search.php:19
231
+ msgid "Keyword"
232
+ msgstr "关键词"
233
+
234
+ #: ../dashboard/noresult.php:19 ../dashboard/search.php:19
235
+ msgid "Requests"
236
+ msgstr "请求"
237
+
238
+ #: ../dashboard/noresult.php:19 ../dashboard/search.php:19
239
+ #: ../dashboard/visitors.php:59
240
+ msgid "Bounced"
241
+ msgstr "弹出次数"
242
+
243
+ #: ../dashboard/overview.php:57 ../shortcodes/overview.php:39
244
+ msgid "Unique visitors"
245
+ msgstr "独立访客"
246
+
247
+ #: ../dashboard/overview.php:58 ../shortcodes/overview.php:40
248
+ msgid "Page views"
249
+ msgstr "页面浏览量(PV)"
250
+
251
+ #: ../dashboard/overview.php:59 ../shortcodes/overview.php:41
252
+ msgid "Max. page views in one visit"
253
+ msgstr "单次访问中最大页面浏览量"
254
+
255
+ #: ../dashboard/overview.php:60 ../shortcodes/overview.php:42
256
+ msgid "Total time spent"
257
+ msgstr "总停留时长"
258
+
259
+ #: ../dashboard/overview.php:61 ../shortcodes/overview.php:43
260
+ msgid "Time/visit"
261
+ msgstr "平均每次访问的停留时长"
262
+
263
+ #: ../dashboard/overview.php:62 ../shortcodes/overview.php:44
264
+ msgid "Bounce count"
265
+ msgstr "弹出次数"
266
+
267
+ #: ../dashboard/overview.php:64 ../settings/views.php:40
268
+ msgid "Shortcut"
269
+ msgstr "便捷链接"
270
+
271
+ #: ../dashboard/pages.php:23
272
+ msgid "Page"
273
+ msgstr "页面"
274
+
275
+ #: ../dashboard/pages.php:25 ../dashboard/plugins.php:34
276
+ #: ../dashboard/visitors.php:57
277
+ msgid "Visits"
278
+ msgstr "访问"
279
+
280
+ #: ../dashboard/visitors.php:48
281
+ msgid ""
282
+ "The graph contains the values shown in the table below (visitors / unique / "
283
+ "bounces). The red line show a linear trendline (unique)."
284
+ msgstr ""
285
+ "图表中反映的是下边表格里的数据(访客、独立访客、弹出次数)。红色线条表示线性"
286
+ "趋势走向(独立访客)。"
287
+
288
+ #: ../dashboard/visitors.php:56
289
+ msgid "Date"
290
+ msgstr "日期"
291
+
292
+ #: ../dashboard/visitors.php:74
293
+ msgid "Unique TOTAL"
294
+ msgstr "独立访客总数"
295
+
296
+ #: ../dashboard/visitors.php:74
297
+ msgid "Sum"
298
+ msgstr "统计"
299
+
300
+ #: ../dashboard/visitors.php:74
301
+ msgid "Avg"
302
+ msgstr "平均"
303
+
304
+ #: ../dashboard/websites.php:21
305
+ msgid "Website"
306
+ msgstr "站点"
307
+
308
+ #: ../settings/credits.php:3
309
+ msgid "Thank you very much for your donation"
310
+ msgstr "十分感谢您的捐赠"
311
+
312
+ #: ../settings/credits.php:3
313
+ msgid "the Piwik team itself"
314
+ msgstr "Piwik 团队本身"
315
+
316
+ #: ../settings/credits.php:3
317
+ msgid ", and all people flattering this"
318
+ msgstr ",所有谈论到它的人们"
319
+
320
+ #: ../settings/credits.php:8
321
+ msgid ""
322
+ "Graphs powered by <a href=\"http://www.jqplot.com/\">jqPlot</a> (License: "
323
+ "GPL 2.0 and MIT) and <a href=\"http://omnipotent.net/jquery.sparkline/"
324
+ "\">jQuery Sparklines</a> (License: New BSD License)."
325
+ msgstr ""
326
+ "图表由 <a href=\"http://www.jqplot.com/\">jqPlot</a>(许可:GPL 2.0 and MIT)"
327
+ "以及 <a href=\"http://omnipotent.net/jquery.sparkline/\">jQuery Sparklines</"
328
+ "a>(许可:New BSD License)强力驱动。"
329
+
330
+ #: ../settings/credits.php:13
331
+ msgid "Metabox support inspired by"
332
+ msgstr "Metabox 支持灵感来源于"
333
+
334
+ #: ../settings/credits.php:14
335
+ msgid "Tabbed settings page suggested by the"
336
+ msgstr "标签式设置页面的建议来自"
337
+
338
+ #: ../settings/credits.php:19
339
+ msgid "Thank you very much"
340
+ msgstr "非常感谢"
341
+
342
+ #: ../settings/credits.php:19
343
+ msgid ", and"
344
+ msgstr ","
345
+
346
+ #: ../settings/credits.php:19
347
+ msgid "for your translation work"
348
+ msgstr "你们的翻译作品"
349
+
350
+ #: ../settings/credits.php:24
351
+ msgid ""
352
+ "Thank you very much, all users who send me mails containing criticism, "
353
+ "commendation, feature requests and bug reports! You help me to make WP-Piwik "
354
+ "much better."
355
+ msgstr ""
356
+ "非常感谢,所有给我发邮件提出批评、建议、功能请求和 bug 报告的用户们!是你们帮"
357
+ "助我把 WP-Piwik 做得更好。"
358
+
359
+ #: ../settings/credits.php:29
360
+ msgid ""
361
+ "Thank <strong>you</strong> for using my plugin. It is the best commendation "
362
+ "if my piece of code is really used!"
363
+ msgstr ""
364
+ "感谢<strong>你</strong>使用我的插件。我的代码能帮到你,就是对我最大的嘉奖了!"
365
+
366
+ #: ../settings/homepage.php:4
367
+ msgid "Thanks for using WP-Piwik!"
368
+ msgstr "感谢使用 WP-Piwik!"
369
+
370
+ #: ../settings/homepage.php:8
371
+ msgid "You are using Piwik"
372
+ msgstr "你正在使用 Piwik"
373
+
374
+ #: ../settings/homepage.php:8
375
+ msgid "and"
376
+ msgstr "和"
377
+
378
+ #: ../settings/homepage.php:8
379
+ msgid "in network mode"
380
+ msgstr "在网络模式中"
381
+
382
+ #: ../settings/homepage.php:10
383
+ msgid "Auto site configuration is"
384
+ msgstr "自动站点配置目前为"
385
+
386
+ #: ../settings/homepage.php:10 ../settings/homepage.php:11
387
+ #: ../settings/support.php:23
388
+ msgid "enabled"
389
+ msgstr "启用"
390
+
391
+ #: ../settings/homepage.php:10 ../settings/homepage.php:11
392
+ msgid "disabled"
393
+ msgstr "禁用"
394
+
395
+ #: ../settings/homepage.php:11
396
+ msgid "Tracking code insertion is"
397
+ msgstr "跟踪代码插入状态目前为"
398
+
399
+ #: ../settings/piwik.php:7 ../settings/sitebrowser.php:7
400
+ #: ../settings/tracking.php:7 ../settings/views.php:7
401
+ msgid ""
402
+ "Error: cURL is not enabled and fopen is not allowed to open URLs. WP-Piwik "
403
+ "won't be able to connect to Piwik."
404
+ msgstr "错误:cURL 未启用,fopen 无法打开 URL。WP-Piwik 无法连接到 Piwik。"
405
+
406
+ #: ../settings/piwik.php:11
407
+ msgid "To enable Piwik statistics, please enter"
408
+ msgstr "要启用 Piwik 统计,请输入"
409
+
410
+ #: ../settings/piwik.php:13
411
+ msgid ""
412
+ "your Piwik base URL (like http://mydomain.com/piwik) or your Piwik server "
413
+ "path (like /var/www/mydomain.com/httpdocs/piwik/)"
414
+ msgstr ""
415
+ "你的 Piwik 站点基础 URL(类似于 http://mydomain.com/piwik)或者你的 Piwik 服"
416
+ "务器路径(类似于 var/www/mydomain.com/httpdocs/piwik/)"
417
+
418
+ #: ../settings/piwik.php:14
419
+ msgid ""
420
+ "your personal Piwik authentification token. You can get the token on the API "
421
+ "page inside your Piwik interface. It looks like "
422
+ "&quot;1234a5cd6789e0a12345b678cd9012ef&quot;."
423
+ msgstr ""
424
+ "你的个人 Piwik 认证令牌。你可以在你的 Piwik 设置界面的 API 页面中找到该令牌。"
425
+ "它看起来和这个类似 &quot;1234a5cd6789e0a12345b678cd9012ef&quot;。"
426
+
427
+ #: ../settings/piwik.php:16
428
+ msgid "No idea what I'm talking about?"
429
+ msgstr "完全不懂我在说什么?"
430
+
431
+ #: ../settings/piwik.php:16
432
+ msgid "Get help."
433
+ msgstr "查看帮助。"
434
+
435
+ #: ../settings/piwik.php:18
436
+ msgid ""
437
+ "<strong>Important note:</strong> If you do not host this blog on your own, "
438
+ "your site admin is able to get your auth token from the database."
439
+ msgstr ""
440
+ "<strong>重要:</strong>如果这个博客不是由你自己架设的,你的站点管理员可以帮你"
441
+ "从数据库里查找到认证令牌。"
442
+
443
+ #: ../settings/piwik.php:22
444
+ msgid "Piwik URL"
445
+ msgstr "Piwik URL"
446
+
447
+ #: ../settings/piwik.php:29
448
+ msgid "Piwik path"
449
+ msgstr "Piwik 路径"
450
+
451
+ #: ../settings/piwik.php:33
452
+ msgid ""
453
+ "If you like to use the PHP API and also to enable tracking by WP-Piwik, "
454
+ "please enter your Piwik URL, too. Otherwise your tracking code may be "
455
+ "erroneous."
456
+ msgstr ""
457
+ "如果你喜欢用 PHP API 并且想要启用 WP-Piwik 跟踪功能,请同样输入你的 Piwik "
458
+ "URL。否则你的跟踪代码可能会出问题。"
459
+
460
+ #: ../settings/piwik.php:36
461
+ msgid "Invalid path. Please enter the file path to Piwik."
462
+ msgstr "路径不正确。请输入到 Piwik 的文件路径。"
463
+
464
+ #: ../settings/piwik.php:40
465
+ msgid "Auth token"
466
+ msgstr "认证令牌(Auth Token)"
467
+
468
+ #: ../settings/piwik.php:46
469
+ msgid "Auto config"
470
+ msgstr "自动配置"
471
+
472
+ #: ../settings/piwik.php:49
473
+ msgid ""
474
+ "Check this to automatically choose your blog from your Piwik sites by URL. "
475
+ "If your blog is not added to Piwik yet, WP-Piwik will add a new site."
476
+ msgstr ""
477
+ "选中此项,可以根据 URL 来自动从 Piwki 站点中选择你的博客。如果你的博客尚未添"
478
+ "加到 Piwik,那么 WP-Piwik 会自动添加一个新条目。"
479
+
480
+ #: ../settings/piwik.php:57
481
+ msgid ""
482
+ "Please check URL and auth token. You need at least view access to one site."
483
+ msgstr "请检查 URL 和认证令牌,你至少要拥有一个站点的查看权限。"
484
+
485
+ #: ../settings/piwik.php:65
486
+ msgid "Choose site"
487
+ msgstr "选择站点"
488
+
489
+ #: ../settings/piwik.php:79
490
+ msgid "Determined site"
491
+ msgstr "判断站点"
492
+
493
+ #: ../settings/piwik.php:92
494
+ msgid "Expert Settings"
495
+ msgstr "高级设置"
496
+
497
+ #: ../settings/piwik.php:94
498
+ msgid "Connection timeout"
499
+ msgstr "连接超时"
500
+
501
+ #: ../settings/piwik.php:101
502
+ msgid "Disable SSL peer verification"
503
+ msgstr "禁用 SSL 端点认证"
504
+
505
+ #: ../settings/piwik.php:103
506
+ msgid "not recommended"
507
+ msgstr "不推荐"
508
+
509
+ #: ../settings/piwik.php:106
510
+ msgid "User agent"
511
+ msgstr "用户代理(UA)"
512
+
513
+ #: ../settings/piwik.php:118
514
+ msgid ""
515
+ "Further expert settings require cURL. See <a href=\"http://www.php.net/"
516
+ "manual/curl.setup.php\">PHP manual</a>"
517
+ msgstr ""
518
+ "高级设置要求启用 cURL。请查看 <a href=\"http://www.php.net/manual/curl.setup."
519
+ "php\">PHP 手册</a>"
520
+
521
+ #: ../settings/sitebrowser.php:26
522
+ msgid "ID"
523
+ msgstr "ID"
524
+
525
+ #: ../settings/sitebrowser.php:27
526
+ msgid "Title"
527
+ msgstr "标题"
528
+
529
+ #: ../settings/sitebrowser.php:28
530
+ msgid "URL"
531
+ msgstr "URL"
532
+
533
+ #: ../settings/sitebrowser.php:29
534
+ msgid "Site ID (Piwik)"
535
+ msgstr "站点 ID(Piwik)"
536
+
537
+ #: ../settings/support.php:2
538
+ msgid "WP-Piwik support board"
539
+ msgstr "WP-Piwik 支持公告板"
540
+
541
+ #: ../settings/support.php:2
542
+ msgid "no registration required, English &amp; German"
543
+ msgstr "无需注册,英语和德语"
544
+
545
+ #: ../settings/support.php:5
546
+ msgid "WordPress.org forum about WP-Piwik"
547
+ msgstr "WordPress.org 论坛的 WP-Piwik 板块"
548
+
549
+ #: ../settings/support.php:5
550
+ msgid "WordPress.org registration required, English"
551
+ msgstr "WordPress.org 需要注册,英语"
552
+
553
+ #: ../settings/support.php:12
554
+ msgid "Debugging"
555
+ msgstr "正在除错"
556
+
557
+ #: ../settings/support.php:13
558
+ msgid ""
559
+ "Either allow_url_fopen has to be enabled <em>or</em> cURL has to be "
560
+ "available:"
561
+ msgstr "要么必须启用 allow_url_fopen,要么使用 cURL:"
562
+
563
+ #: ../settings/support.php:16
564
+ msgid "cURL is"
565
+ msgstr "cURL 现在"
566
+
567
+ #: ../settings/support.php:17 ../settings/support.php:22
568
+ msgid "not"
569
+ msgstr "不"
570
+
571
+ #: ../settings/support.php:18
572
+ msgid "available"
573
+ msgstr "可用"
574
+
575
+ #: ../settings/support.php:21
576
+ msgid "allow_url_fopen is"
577
+ msgstr "allow_url_fopen 现在"
578
+
579
+ #: ../settings/support.php:31
580
+ msgid "Test script result"
581
+ msgstr "测试脚本结果"
582
+
583
+ #: ../settings/support.php:35
584
+ msgid "Please confirm your reset request"
585
+ msgstr "请确认你的重置请求"
586
+
587
+ #: ../settings/support.php:35
588
+ msgid ""
589
+ "YES, please reset <strong>all</strong> WP-Piwik settings <strong>except</"
590
+ "strong> auth token and Piwi URL."
591
+ msgstr ""
592
+ "是,请重置<strong>所有</strong> WP-Piwik 设置,<strong>除了</strong>认证令牌"
593
+ "和 Piwik URL。"
594
+
595
+ #: ../settings/support.php:41
596
+ msgid "WP-Piwik reset done"
597
+ msgstr "WP-Piwik 重置完成"
598
+
599
+ #: ../settings/support.php:46
600
+ msgid "Get more debug information"
601
+ msgstr "获取更多除错信息"
602
+
603
+ #: ../settings/support.php:48
604
+ msgid "Run test script"
605
+ msgstr "运行测试脚本"
606
+
607
+ #: ../settings/support.php:49
608
+ msgid "Get site configuration details"
609
+ msgstr "获取站点配置细节"
610
+
611
+ #: ../settings/support.php:50
612
+ msgid "Reset WP-Piwik settings except auth token and Piwik URL"
613
+ msgstr "重置 WP-Piwki 设置,除了认证令牌和 Piwki URL"
614
+
615
+ #: ../settings/support.php:50
616
+ msgid ""
617
+ "This will not affect Piwik itself. Resetting large networks may take some "
618
+ "minutes."
619
+ msgstr "这样不会影响 Piwik 本身。重置大型网络时可能需要更多时间。"
620
+
621
+ #: ../settings/support.php:52
622
+ msgid ""
623
+ "You have to enter your auth token and the Piwik URL before you can access "
624
+ "more debug functions."
625
+ msgstr "你需要输入认证令牌和 Piwik URL,然后才可以使用更多除错功能。"
626
+
627
+ #: ../settings/support.php:55
628
+ msgid "Latest support threads on WordPress.org"
629
+ msgstr "WordPress.org 上的最新支持讨论"
630
+
631
+ #: ../settings/tracking.php:10
632
+ msgid "Add tracking code"
633
+ msgstr "添加跟踪代码"
634
+
635
+ #: ../settings/tracking.php:14
636
+ msgid ""
637
+ "If your template uses wp_footer(), WP-Piwik can automatically add the Piwik "
638
+ "javascript code to your blog."
639
+ msgstr ""
640
+ "如果你的模板使用了 wp_footer() 函数,WP-Piwik 则可以自动把 Piwik 脚本代码插入"
641
+ "到你的博客中。"
642
+
643
+ #: ../settings/tracking.php:31
644
+ msgid "Tracking code preview"
645
+ msgstr "跟踪代码预览"
646
+
647
+ #: ../settings/tracking.php:37
648
+ msgid "&lt;noscript&gt; code preview"
649
+ msgstr "&lt;noscript&gt; 代码预览"
650
+
651
+ #: ../settings/tracking.php:43
652
+ msgid "Default tracking"
653
+ msgstr "默认跟踪"
654
+
655
+ #: ../settings/tracking.php:45
656
+ msgid "WP-Piwik uses the Piwik default tracking code."
657
+ msgstr "WP-Piwik 使用 Piwik 的默认跟踪代码"
658
+
659
+ #: ../settings/tracking.php:48
660
+ msgid "Use js/index.php"
661
+ msgstr "使用 js/index.php"
662
+
663
+ #: ../settings/tracking.php:50
664
+ msgid ""
665
+ "WP-Piwik can automatically use js/index.php instead of piwik.js and piwik."
666
+ "php. See"
667
+ msgstr ""
668
+ "WP-Piwik 可以自动使用 js/index.php,从而取代 piwik.js 和 piwik.php。请查看"
669
+
670
+ #: ../settings/tracking.php:53
671
+ msgid "Use proxy script"
672
+ msgstr "使用代理脚本"
673
+
674
+ #: ../settings/tracking.php:55
675
+ msgid "WP-Piwik will use the piwik.php proxy script. See"
676
+ msgstr "WP-Piwik 要使用 piwik.php 代理脚本。请查看"
677
+
678
+ #: ../settings/tracking.php:59
679
+ msgid "Add &lt;noscript&gt;"
680
+ msgstr "添加 &lt;noscript&gt;"
681
+
682
+ #: ../settings/tracking.php:61
683
+ msgid "Adds the &lt;noscript&gt; code to your footer."
684
+ msgstr "添加 &lt;noscript&gt; 代码到你的 footer 部分。"
685
+
686
+ #: ../settings/tracking.php:61 ../settings/tracking.php:66
687
+ #: ../settings/tracking.php:86
688
+ msgid "Disabled in proxy mode."
689
+ msgstr "在代理模式下不可用"
690
+
691
+ #: ../settings/tracking.php:64
692
+ msgid "Add rec parameter to noscript code"
693
+ msgstr "在 noscript 代码中添加 rec 参数"
694
+
695
+ #: ../settings/tracking.php:66
696
+ msgid "Enable tracking for visitors without JavaScript (not recommended). See"
697
+ msgstr "对未启用 JavaScript 的访客启用跟踪(不推荐)。请查看"
698
+
699
+ #: ../settings/tracking.php:69
700
+ msgid "Disable cookies"
701
+ msgstr "禁用 Cookie"
702
+
703
+ #: ../settings/tracking.php:71
704
+ msgid "Disable all tracking cookies for a visitor."
705
+ msgstr "对某访问者禁用所有跟踪 Cookie"
706
+
707
+ #: ../settings/tracking.php:74
708
+ msgid "Track search"
709
+ msgstr "跟踪搜索"
710
+
711
+ #: ../settings/tracking.php:76
712
+ msgid "Use Piwik's advanced Site Search Analytics feature. See"
713
+ msgstr "使用 Piwik 的高级站点搜索分析功能。请查看"
714
+
715
+ #: ../settings/tracking.php:79
716
+ msgid "Track 404"
717
+ msgstr "跟踪 404"
718
+
719
+ #: ../settings/tracking.php:81
720
+ msgid "WP-Piwik can automatically add a 404-category to track 404-page-visits."
721
+ msgstr "WP-Piwik 会自动添加一个 404 目录来跟踪 404 页面的访问"
722
+
723
+ #: ../settings/tracking.php:84
724
+ msgid "Avoid mod_security"
725
+ msgstr "避免 mod_security"
726
+
727
+ #: ../settings/tracking.php:86
728
+ msgid ""
729
+ "WP-Piwik can automatically force the Tracking Code to sent data in POST. See"
730
+ msgstr "WP-Piwik 会自动强制跟踪代码以 POST 的方式发送信息。请查看"
731
+
732
+ #: ../settings/tracking.php:89
733
+ msgid "Enable cache"
734
+ msgstr "启用缓存"
735
+
736
+ #: ../settings/tracking.php:91
737
+ msgid "Cache API calls, which not contain today's values, for a week"
738
+ msgstr "缓存 API,其不包含当天的数值,为期一周"
739
+
740
+ #: ../settings/tracking.php:94
741
+ msgid "CDN URL"
742
+ msgstr "CDN URL"
743
+
744
+ #: ../settings/tracking.php:96
745
+ msgid ""
746
+ "Leave blank if you do not want to define a CDN URL or you do not know what "
747
+ "this is."
748
+ msgstr "如果不需要定义 CDN URL,或者你不清楚这是什么,请留空。"
749
+
750
+ #: ../settings/tracking.php:99
751
+ msgid "Tracking filter"
752
+ msgstr "跟踪过滤器"
753
+
754
+ #: ../settings/tracking.php:106
755
+ msgid "Choose users by user role you do <strong>not</strong> want to track."
756
+ msgstr "选择你<strong>不</strong>需要跟踪的用户组"
757
+
758
+ #: ../settings/views.php:10
759
+ msgid "WP-Piwik display name"
760
+ msgstr "WP-Piwik 显示名称"
761
+
762
+ #: ../settings/views.php:12
763
+ msgid "Plugin name shown in WordPress."
764
+ msgstr "在 WordPress 中显示的插件名称。"
765
+
766
+ #: ../settings/views.php:14
767
+ msgid "Default date"
768
+ msgstr "默认日期"
769
+
770
+ #: ../settings/views.php:16 ../settings/views.php:24
771
+ msgid "yesterday"
772
+ msgstr "昨天"
773
+
774
+ #: ../settings/views.php:17 ../settings/views.php:25
775
+ msgid "today"
776
+ msgstr "今天"
777
+
778
+ #: ../settings/views.php:19
779
+ msgid "Default date shown on statistics page."
780
+ msgstr "在统计数据页面显示的默认日期。"
781
+
782
+ #: ../settings/views.php:21
783
+ msgid "Home Dashboard"
784
+ msgstr "仪表盘首页"
785
+
786
+ #: ../settings/views.php:23
787
+ msgid "Hide overview"
788
+ msgstr "隐藏概览"
789
+
790
+ #: ../settings/views.php:24 ../settings/views.php:25 ../settings/views.php:26
791
+ msgid "Show overview"
792
+ msgstr "显示概览"
793
+
794
+ #: ../settings/views.php:26
795
+ msgid "last 30 days"
796
+ msgstr "最近 30 天"
797
+
798
+ #: ../settings/views.php:28
799
+ msgid "Chart"
800
+ msgstr "图表"
801
+
802
+ #: ../settings/views.php:29
803
+ msgid "SEO <em>(slow!)</em>"
804
+ msgstr "SEO(很慢!)"
805
+
806
+ #: ../settings/views.php:30
807
+ msgid ""
808
+ "Configure WP-Piwik widgets to be shown on your WordPress Home Dashboard."
809
+ msgstr "配置 WP-Piwik 挂件,以显示在你的 WordPress 仪表盘首页上。"
810
+
811
+ #: ../settings/views.php:32
812
+ msgid "Show graph on WordPress Toolbar"
813
+ msgstr "在 WordPress 工具条上显示图表"
814
+
815
+ #: ../settings/views.php:34
816
+ msgid "Display the last 30 days visitor stats on WordPress Toolbar."
817
+ msgstr "在 WordPress 工具条上显示最近 30 天里的访客统计"
818
+
819
+ #: ../settings/views.php:36
820
+ msgid "SEO data"
821
+ msgstr "SEO 数据"
822
+
823
+ #: ../settings/views.php:38
824
+ msgid "Display SEO ranking data on statistics page. <em>(Slow!)</em>"
825
+ msgstr "在统计数据页面显示 SEO 排名数据(很慢!)"
826
+
827
+ #: ../settings/views.php:42
828
+ msgid "Display a shortcut to Piwik itself."
829
+ msgstr "显示到 Piwik 本身的链接。"
830
+
831
+ #: ../settings/views.php:44
832
+ msgid "Display to"
833
+ msgstr "显示在"
834
+
835
+ #: ../settings/views.php:51
836
+ msgid "Choose user roles allowed to see the statistics page."
837
+ msgstr "选择能够查看统计页面的用户组"
838
+
839
+ #: ../settings/views.php:53
840
+ msgid "Disable time limit"
841
+ msgstr "禁用时间限制"
842
+
843
+ #: ../settings/views.php:55
844
+ msgid "Use set_time_limit(0) if stats page causes a time out."
845
+ msgstr "如果统计数据页面出现超时,请使用 set_time_limit(0)。"
846
+
847
+ #: ../settings/views.php:57
848
+ msgid "Enable shortcodes"
849
+ msgstr "启用短代码"
850
+
851
+ #: ../settings/views.php:59
852
+ msgid "Enable shortcodes in post or page content."
853
+ msgstr "启用短代码,可以插入到文章或页面内容中。"
854
+
855
+ #: ../shortcodes/overview.php:26
856
+ msgid "Error"
857
+ msgstr "错误"
858
+
859
+ #: ../shortcodes/overview.php:46
860
+ msgid "No data available"
861
+ msgstr "暂无数据"
readme.txt CHANGED
@@ -3,7 +3,7 @@
3
  Contributors: Braekling
4
  Requires at least: 3.8
5
  Tested up to: 3.8
6
- Stable tag: 0.9.9.7
7
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=6046779
8
  Tags: statistics, stats, analytics, piwik, wpmu
9
 
@@ -19,7 +19,7 @@ Look at the [Piwik website](http://piwik.org/) to get further information about
19
 
20
  *This plugin is not created or provided by the Piwik project team.*
21
 
22
- Languages: English, German, Albanian, Azerbaijani, Belorussian, Dutch, French, Greek, Italian, Lithuanian, Norwegian, Persian, Romanian, Russian, Spanish, Swedish, Ukrainian
23
 
24
  *Note: If you vote "It's broken", please tell me about your problem. It's hard to fix a bug I don't know about! ;-)*
25
 
@@ -117,6 +117,10 @@ Please update Piwik if not done yet (Piwik 1.11 or higher is recommended)!
117
 
118
  == Changelog ==
119
 
 
 
 
 
120
  = 0.9.9.7 =
121
  * Bugfix: Error messages won't by cached anymore
122
  * Bugfix: Custom vars will now be added properly
3
  Contributors: Braekling
4
  Requires at least: 3.8
5
  Tested up to: 3.8
6
+ Stable tag: 0.9.9.8
7
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=6046779
8
  Tags: statistics, stats, analytics, piwik, wpmu
9
 
19
 
20
  *This plugin is not created or provided by the Piwik project team.*
21
 
22
+ Languages: English, German, Albanian, Azerbaijani, Belorussian, Chinese (simplified), Dutch, French, Greek, Italian, Lithuanian, Norwegian, Persian, Romanian, Russian, Spanish, Swedish, Ukrainian
23
 
24
  *Note: If you vote "It's broken", please tell me about your problem. It's hard to fix a bug I don't know about! ;-)*
25
 
117
 
118
  == Changelog ==
119
 
120
+ = 0.9.9.8 =
121
+ * Feature: Per post stats (shown at the edit post page)
122
+ * Feature: Track RSS views using a measurement pixel
123
+
124
  = 0.9.9.7 =
125
  * Bugfix: Error messages won't by cached anymore
126
  * Bugfix: Custom vars will now be added properly
settings/credits.php CHANGED
@@ -1,6 +1,6 @@
1
  <tr>
2
  <td>
3
- <strong><?php _e('Thank you very much for your donation', 'wp-piwik'); ?>:</strong> Marco L., Rolf W., Tobias U., Lars K., Donna F., Kevin D., Ramos S., Thomas M., John C., Andreas G., Ben M., Myra R. I., Carlos U. R.-S., <?php _e('the Piwik team itself','wp-piwik');?><?php _e(', and all people flattering this','wp-piwik'); ?>!
4
  </td>
5
  </tr>
6
  <tr>
@@ -16,7 +16,7 @@
16
  </tr>
17
  <tr>
18
  <td>
19
- <?php _e('Thank you very much','wp-piwik'); ?>, <a href="http://blogu.programeshqip.org/">Besnik Bleta</a>, <a href="http://www.fatcow.com/">FatCow</a>, <a href="http://www.pamukkaleturkey.com/">Rene</a>, Fab, <a href="http://ezbizniz.com/">EzBizNiz</a>, Gormer, Natalya, <a href="www.aggeliopolis.gr">AggelioPolis</a><?php _e(', and', 'wp-piwik'); ?> <a href="http://wwww.webhostinggeeks.com">Web Hosting Geeks</a>, <a href="http://www.webhostingrating.com">Web Hosting Rating</a>, <a href="http://www.webhostinghub.com">Nata Strazda (Web Hosting Hub)</a>, <a href="http://www.libreoffice.ir">Hossein, LibreOffice localization team</a> &amp; <a href="http://www.vogliaditerra.com">Ste</a> <?php _e('for your translation work','wp-piwik'); ?>!
20
  </td>
21
  </tr>
22
  <tr>
1
  <tr>
2
  <td>
3
+ <strong><?php _e('Thank you very much for your donation', 'wp-piwik'); ?>:</strong> Marco L., Rolf W., Tobias U., Lars K., Donna F., Kevin D., Ramos S., Thomas M., John C., Andreas G., Ben M., Myra R. I., Carlos U. R.-S., Oleg I., M. N., <?php _e('the Piwik team itself','wp-piwik');?><?php _e(', and all people flattering this','wp-piwik'); ?>!
4
  </td>
5
  </tr>
6
  <tr>
16
  </tr>
17
  <tr>
18
  <td>
19
+ <?php _e('Thank you very much','wp-piwik'); ?>, <a href="http://blogu.programeshqip.org/">Besnik Bleta</a>, <a href="http://www.fatcow.com/">FatCow</a>, <a href="http://www.pamukkaleturkey.com/">Rene</a>, Fab, <a href="http://ezbizniz.com/">EzBizNiz</a>, Gormer, Natalya, <a href="www.aggeliopolis.gr">AggelioPolis</a><?php _e(', and', 'wp-piwik'); ?> <a href="http://wwww.webhostinggeeks.com">Web Hosting Geeks</a>, <a href="http://www.webhostingrating.com">Web Hosting Rating</a>, <a href="http://www.webhostinghub.com">Nata Strazda (Web Hosting Hub)</a>, <a href="http://www.libreoffice.ir">Hossein, LibreOffice localization team</a>, <a href="http://www.vogliaditerra.com">Ste</a> &amp; Chris <?php _e('for your translation work','wp-piwik'); ?>!
20
  </td>
21
  </tr>
22
  <tr>
settings/homepage.php CHANGED
@@ -5,7 +5,7 @@ $strVersion = $this->callPiwikAPI('API.getPiwikVersion');
5
  <tr><td><?php
6
  if (is_array($strVersion) && $strVersion['result'] == 'error') self::showErrorMessage($strVersion['message']);
7
  elseif (empty($strVersion)) self::showErrorMessage('Piwik did not answer. Please check your entered Piwik URL.');
8
- else echo __('You are using Piwik','wp-piwik').' '.$strVersion.' '.__('and', 'wp-piwik').' WP-Piwik '.self::$strVersion.(is_plugin_active_for_network('wp-piwik/wp-piwik.php')?' '.__('in network mode'):'').'.';
9
  ?></td></tr>
10
  <tr><td><?php _e('Auto site configuration is','wp-piwik'); ?> <strong><?php echo (self::$settings->getGlobalOption('auto_site_config')?__('enabled','wp-piwik'):__('disabled','wp-piwik')); ?>.</strong></td></tr>
11
  <tr><td><?php _e('Tracking code insertion is','wp-piwik'); ?> <strong><?php echo (self::$settings->getGlobalOption('add_tracking_code')?__('enabled','wp-piwik'):__('disabled','wp-piwik')); ?>.</strong></td></tr>
5
  <tr><td><?php
6
  if (is_array($strVersion) && $strVersion['result'] == 'error') self::showErrorMessage($strVersion['message']);
7
  elseif (empty($strVersion)) self::showErrorMessage('Piwik did not answer. Please check your entered Piwik URL.');
8
+ else echo __('You are using Piwik','wp-piwik').' '.$strVersion.' '.__('and', 'wp-piwik').' WP-Piwik '.self::$strVersion.(is_plugin_active_for_network('wp-piwik/wp-piwik.php')?' '.__('in network mode', 'wp-piwik'):'').'.';
9
  ?></td></tr>
10
  <tr><td><?php _e('Auto site configuration is','wp-piwik'); ?> <strong><?php echo (self::$settings->getGlobalOption('auto_site_config')?__('enabled','wp-piwik'):__('disabled','wp-piwik')); ?>.</strong></td></tr>
11
  <tr><td><?php _e('Tracking code insertion is','wp-piwik'); ?> <strong><?php echo (self::$settings->getGlobalOption('add_tracking_code')?__('enabled','wp-piwik'):__('disabled','wp-piwik')); ?>.</strong></td></tr>
settings/support.php CHANGED
@@ -1,8 +1,5 @@
1
  <tr>
2
- <td><a href="http://peepbo.de/board/viewforum.php?f=3"><?php _e('WP-Piwik support board','wp-piwik'); ?></a> (<?php _e('no registration required, English &amp; German','wp-piwik'); ?>)</td>
3
- </tr>
4
- <tr>
5
- <td><a href="http://wordpress.org/tags/wp-piwik?forum_id=10"><?php _e('WordPress.org forum about WP-Piwik','wp-piwik'); ?></a> (<?php _e('WordPress.org registration required, English','wp-piwik'); ?>)</td>
6
  </tr>
7
  <tr>
8
  <td><?php _e('Please don\'t forget to vote the compatibility at the','wp-piwik'); ?> <a href="http://wordpress.org/extend/plugins/wp-piwik/">WordPress.org Plugin Directory</a>.</td>
1
  <tr>
2
+ <td><a href="http://wordpress.org/tags/wp-piwik?forum_id=10"><?php _e('WordPress.org forum about WP-Piwik','wp-piwik'); ?></a></td>
 
 
 
3
  </tr>
4
  <tr>
5
  <td><?php _e('Please don\'t forget to vote the compatibility at the','wp-piwik'); ?> <a href="http://wordpress.org/extend/plugins/wp-piwik/">WordPress.org Plugin Directory</a>.</td>
settings/tracking.php CHANGED
@@ -93,7 +93,18 @@ if (self::$settings->getGlobalOption('add_tracking_code')) {
93
 
94
  <tr><th><?php _e('Track admin pages', 'wp-piwik'); ?>:</th><td>
95
  <input type="checkbox" value="1" id="wp-piwik_trackadmin" name="wp-piwik_trackadmin"<?php echo (self::$settings->getGlobalOption('track_admin')?' checked="checked"':''); ?> />
96
- <label for="wp-piwik_trackadmin"><?php _e('Enable to track users on admin pages (remember to configure the tracking filter appropriately).'); ?></label>
 
 
 
 
 
 
 
 
 
 
 
97
  </td></tr>
98
 
99
  <tr><th><?php _e('Tracking filter', 'wp-piwik'); ?>:</th><td>
93
 
94
  <tr><th><?php _e('Track admin pages', 'wp-piwik'); ?>:</th><td>
95
  <input type="checkbox" value="1" id="wp-piwik_trackadmin" name="wp-piwik_trackadmin"<?php echo (self::$settings->getGlobalOption('track_admin')?' checked="checked"':''); ?> />
96
+ <label for="wp-piwik_trackadmin"><?php _e('Enable to track users on admin pages (remember to configure the tracking filter appropriately).', 'wp-piwik'); ?></label>
97
+ </td></tr>
98
+
99
+ <tr><th><?php _e('Track RSS feeds', 'wp-piwik'); ?>:</th><td>
100
+ <input type="checkbox" value="1" id="wp-piwik_trackfeed" name="wp-piwik_trackfeed"<?php echo (self::$settings->getGlobalOption('track_feed')?' checked="checked"':''); ?> />
101
+ <label for="wp-piwik_trackfeed"><?php _e('Enable to track posts in feeds via tracking pixel.', 'wp-piwik'); ?></label>
102
+ </td></tr>
103
+
104
+ <tr><th><?php _e('Track RSS feed links as campaign', 'wp-piwik'); ?>:</th><td>
105
+ <input type="checkbox" value="1" id="wp-piwik_trackfeed_addcampaign" name="wp-piwik_trackfeed_addcampaign"<?php echo (self::$settings->getGlobalOption('track_feed_addcampaign')?' checked="checked"':''); ?> />
106
+ <label for="wp-piwik_trackfeed_addcampaign"><?php _e('This will add Piwik campaign parameters to the RSS feed links.', 'wp-piwik'); ?> (<a href="https://piwik.org/docs/tracking-campaigns/">Piwik: Tracking campaign</a>)</label><br />
107
+ <?php _e('Campaign', 'wp-piwik'); ?>: <input type="text" value="<?php echo self::$settings->getGlobalOption('track_feed_campaign'); ?>" id="wp-piwik_trackfeed_campaign" name="wp-piwik_trackfeed_campaign"> <?php _e('Keyword: post name.', 'wp-piwik'); ?>
108
  </td></tr>
109
 
110
  <tr><th><?php _e('Tracking filter', 'wp-piwik'); ?>:</th><td>
settings/views.php CHANGED
@@ -56,7 +56,7 @@ if (!$bolFOpen && !$bolCURL) {
56
  </td></tr>
57
  <tr><th><?php _e('Show per post stats', 'wp-piwik'); ?>:</th><td>
58
  <input type="checkbox" value="1" id="wp-piwik_perpost" name="wp-piwik_perpost"<?php echo (self::$settings->getGlobalOption('perpost_stats')?' checked="checked"':''); ?> />
59
- <label for="wp-piwik_shortcodes"><?php echo _e('Show stats about single posts at the post edit admin page.', 'wp-piwik'); ?></label>
60
  </td></tr>
61
  <tr><th><?php _e('Enable shortcodes', 'wp-piwik'); ?>:</th><td>
62
  <input type="checkbox" value="1" id="wp-piwik_shortcodes" name="wp-piwik_shortcodes"<?php echo (self::$settings->getGlobalOption('shortcodes')?' checked="checked"':''); ?> />
56
  </td></tr>
57
  <tr><th><?php _e('Show per post stats', 'wp-piwik'); ?>:</th><td>
58
  <input type="checkbox" value="1" id="wp-piwik_perpost" name="wp-piwik_perpost"<?php echo (self::$settings->getGlobalOption('perpost_stats')?' checked="checked"':''); ?> />
59
+ <label for="wp-piwik_perpost"><?php echo _e('Show stats about single posts at the post edit admin page.', 'wp-piwik'); ?></label>
60
  </td></tr>
61
  <tr><th><?php _e('Enable shortcodes', 'wp-piwik'); ?>:</th><td>
62
  <input type="checkbox" value="1" id="wp-piwik_shortcodes" name="wp-piwik_shortcodes"<?php echo (self::$settings->getGlobalOption('shortcodes')?' checked="checked"':''); ?> />
update/90980.php ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
1
+ <?php
2
+ self::$settings->setGlobalOption('track_feed', false);
3
+ self::$settings->setGlobalOption('track_feed_goal', false);
4
+ self::$settings->setGlobalOption('track_feed_revenue', false);
5
+ self::$settings->setGlobalOption('track_feed_campaign', 'feed');
6
+ self::$settings->setGlobalOption('track_feed_addcampaign', false);
wp-piwik.php CHANGED
@@ -6,7 +6,7 @@ Plugin URI: http://wordpress.org/extend/plugins/wp-piwik/
6
 
7
  Description: Adds Piwik stats to your dashboard menu and Piwik code to your wordpress header.
8
 
9
- Version: 0.9.9.7
10
  Author: Andr&eacute; Br&auml;kling
11
  Author URI: http://www.braekling.de
12
 
@@ -42,8 +42,8 @@ if (!class_exists('wp_piwik')) {
42
  class wp_piwik {
43
 
44
  private static
45
- $intRevisionId = 90971,
46
- $strVersion = '0.9.9.7',
47
  $blog_id,
48
  $intDashboardID = 30,
49
  $strPluginBasename = NULL,
@@ -111,6 +111,13 @@ class wp_piwik {
111
  // Add tracking code to admin page header if enabled
112
  if (self::$settings->getGlobalOption('track_admin'))
113
  add_action('admin_head', array($this, 'addAdminHeaderTracking'));
 
 
 
 
 
 
 
114
  }
115
  self::$settings->save();
116
  }
@@ -177,6 +184,8 @@ class wp_piwik {
177
  self::includeFile('update/90961');
178
  if (self::$settings->getGlobalOption('revision') < 90971)
179
  self::includeFile('update/90971');
 
 
180
 
181
  // Install new version
182
  $this->installPlugin();
@@ -322,6 +331,11 @@ class wp_piwik {
322
  function postMetaboxes() {
323
  add_action('add_meta_boxes', array(&$this, 'postAddMetaboxes'));
324
  add_action('save_post', array(&$this, 'postCustomvarsSave'), 10, 2);
 
 
 
 
 
325
  }
326
 
327
  /**
@@ -651,6 +665,44 @@ class wp_piwik {
651
  $this->site_header();
652
  }
653
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
654
  /**
655
  * Add required header tags to stats page
656
  */
@@ -895,11 +947,11 @@ class wp_piwik {
895
  /**
896
  * Call Piwik's API
897
  */
898
- function callPiwikAPI($strMethod, $strPeriod='', $strDate='', $intLimit='',$bolExpanded=false, $intId = false, $strFormat = 'PHP', $strPageURL = '') {
899
  // Create unique cache key
900
- $strKey = 'wp-piwik_'.md5($strMethod.'_'.$strPeriod.'_'.$strDate.'_'.$intLimit.'_'.self::$settings->getGlobalOption('piwik_token').'_'.self::$settings->getGlobalOption('piwik_url'));
901
  // Call API if data not cached
902
- if (self::$settings->getGlobalOption('cache')) {
903
  $result = get_transient($strKey);
904
  self::$logger->log('API method: '.$strMethod.' Fetch call from cache: '.$strKey);
905
  } else $result = false;
@@ -1192,6 +1244,11 @@ class wp_piwik {
1192
  self::$settings->setGlobalOption('track_noscript', (isset($_POST['wp-piwik_noscript'])?$_POST['wp-piwik_noscript']:false));
1193
  self::$settings->setGlobalOption('track_nojavascript', (isset($_POST['wp-piwik_nojavascript'])?$_POST['wp-piwik_nojavascript']:false));
1194
  self::$settings->setGlobalOption('track_admin', (isset($_POST['wp-piwik_trackadmin'])?$_POST['wp-piwik_trackadmin']:false));
 
 
 
 
 
1195
  self::$settings->setGlobalOption('capability_stealth', (isset($_POST['wp-piwik_filter'])?$_POST['wp-piwik_filter']:array()));
1196
  self::$settings->setGlobalOption('disable_cookies', (isset($_POST['wp-piwik_disable_cookies'])?$_POST['wp-piwik_disable_cookies']:false));
1197
  self::$settings->setOption('tracking_code', $this->callPiwikAPI('SitesManager.getJavascriptTag'));
@@ -1390,6 +1447,13 @@ class wp_piwik {
1390
  self::$settings = new WP_Piwik_Settings(self::$logger);
1391
  }
1392
 
 
 
 
 
 
 
 
1393
  }
1394
 
1395
  }
6
 
7
  Description: Adds Piwik stats to your dashboard menu and Piwik code to your wordpress header.
8
 
9
+ Version: 0.9.9.8
10
  Author: Andr&eacute; Br&auml;kling
11
  Author URI: http://www.braekling.de
12
 
42
  class wp_piwik {
43
 
44
  private static
45
+ $intRevisionId = 90983,
46
+ $strVersion = '0.9.9.8',
47
  $blog_id,
48
  $intDashboardID = 30,
49
  $strPluginBasename = NULL,
111
  // Add tracking code to admin page header if enabled
112
  if (self::$settings->getGlobalOption('track_admin'))
113
  add_action('admin_head', array($this, 'addAdminHeaderTracking'));
114
+ // Add tracking image to feed if enabled
115
+ if (self::$settings->getGlobalOption('track_feed')) {
116
+ add_filter('the_excerpt_rss', array(&$this, 'addFeedTracking'));
117
+ add_filter('the_content', array(&$this, 'addFeedTracking'));
118
+ }
119
+ if (self::$settings->getGlobalOption('track_feed_addcampaign'))
120
+ add_filter('post_link', array(&$this, 'addFeedCampaign'));
121
  }
122
  self::$settings->save();
123
  }
184
  self::includeFile('update/90961');
185
  if (self::$settings->getGlobalOption('revision') < 90971)
186
  self::includeFile('update/90971');
187
+ if (self::$settings->getGlobalOption('revision') < 90983)
188
+ self::includeFile('update/90980');
189
 
190
  // Install new version
191
  $this->installPlugin();
331
  function postMetaboxes() {
332
  add_action('add_meta_boxes', array(&$this, 'postAddMetaboxes'));
333
  add_action('save_post', array(&$this, 'postCustomvarsSave'), 10, 2);
334
+ // Show per post stats if enabled
335
+ if (self::$settings->getGlobalOption('perpost_stats')) {
336
+ $this->includeFile('classes/WP_Piwik_MetaBox_PerPost_Stats');
337
+ add_action('add_meta_boxes', array(new WP_Piwik_MetaBox_PerPost_Stats($this->subClassConfig()), 'addMetabox'));
338
+ }
339
  }
340
 
341
  /**
665
  $this->site_header();
666
  }
667
 
668
+ /**
669
+ * Add tracking image to feeds
670
+ **/
671
+ function addFeedTracking($content) {
672
+ global $post;
673
+ if(is_feed()) {
674
+ self::$logger->log('Add tracking image to feed entry.');
675
+ if (!self::$settings->getOption('site_id'))
676
+ self::addPiwikSite();
677
+ $title = the_title(null,null,false);
678
+ $posturl = get_permalink($post->ID);
679
+ $urlref = get_bloginfo('rss2_url');
680
+ $url = self::$settings->getGlobalOption('piwik_url');
681
+ if (substr($url, -10, 10) == '/index.php')
682
+ $url = str_replace('/index.php', '/piwik.php', $url);
683
+ else $url .= 'piwik.php';
684
+ $trackingImage = $url.'?idsite='.self::$settings->getOption('site_id').'&amp;rec=1'.
685
+ '&amp;url='.urlencode($posturl).
686
+ '&amp;action_name='.urlencode($title).
687
+ '&amp;urlref='.urlencode($urlref);
688
+ $content .= '<img src="'.$trackingImage.'" style="border:0;width:0;height:0" width="0" height="0" alt="" />';
689
+ }
690
+ return $content;
691
+ }
692
+
693
+ /**
694
+ * Add tracking image to feeds
695
+ **/
696
+ function addFeedCampaign($permalink) {
697
+ global $post;
698
+ if(is_feed()) {
699
+ self::$logger->log('Add campaign to feed permalink.');
700
+ $sep = (strpos($permalink, '?') === false?'?':'&');
701
+ $permalink .= $sep.'pk_campaign='.urlencode(self::$settings->getGlobalOption('track_feed_campaign')).'&pk_kwd='.urlencode($post->post_name);
702
+ }
703
+ return $permalink;
704
+ }
705
+
706
  /**
707
  * Add required header tags to stats page
708
  */
947
  /**
948
  * Call Piwik's API
949
  */
950
+ function callPiwikAPI($strMethod, $strPeriod='', $strDate='', $intLimit='',$bolExpanded=false, $intId = false, $strFormat = 'PHP', $strPageURL = '', $useCache = true) {
951
  // Create unique cache key
952
+ $strKey = 'wp-piwik_'.md5($strMethod.'_'.$strPeriod.'_'.$strDate.'_'.$intLimit.'_'.self::$settings->getGlobalOption('piwik_token').'_'.self::$settings->getGlobalOption('piwik_url').'_'.$intId.'_'.$strPageURL);
953
  // Call API if data not cached
954
+ if (self::$settings->getGlobalOption('cache') && $useCache) {
955
  $result = get_transient($strKey);
956
  self::$logger->log('API method: '.$strMethod.' Fetch call from cache: '.$strKey);
957
  } else $result = false;
1244
  self::$settings->setGlobalOption('track_noscript', (isset($_POST['wp-piwik_noscript'])?$_POST['wp-piwik_noscript']:false));
1245
  self::$settings->setGlobalOption('track_nojavascript', (isset($_POST['wp-piwik_nojavascript'])?$_POST['wp-piwik_nojavascript']:false));
1246
  self::$settings->setGlobalOption('track_admin', (isset($_POST['wp-piwik_trackadmin'])?$_POST['wp-piwik_trackadmin']:false));
1247
+ self::$settings->setGlobalOption('track_feed', (isset($_POST['wp-piwik_trackfeed'])?$_POST['wp-piwik_trackfeed']:false));
1248
+ self::$settings->setGlobalOption('track_feed_goal', (isset($_POST['wp-piwik_trackfeed_goal'])&&!empty($_POST['wp-piwik_trackfeed_goal'])?(int)$_POST['wp-piwik_trackfeed_goal']:''));
1249
+ self::$settings->setGlobalOption('track_feed_revenue', (isset($_POST['wp-piwik_trackfeed_revenue'])&&!empty($_POST['wp-piwik_trackfeed_revenue'])?(int)$_POST['wp-piwik_trackfeed_revenue']:''));
1250
+ self::$settings->setGlobalOption('track_feed_campaign', (isset($_POST['wp-piwik_trackfeed_campaign'])?$_POST['wp-piwik_trackfeed_campaign']:'feed'));
1251
+ self::$settings->setGlobalOption('track_feed_addcampaign', (isset($_POST['wp-piwik_trackfeed_addcampaign'])?$_POST['wp-piwik_trackfeed_addcampaign']:false));
1252
  self::$settings->setGlobalOption('capability_stealth', (isset($_POST['wp-piwik_filter'])?$_POST['wp-piwik_filter']:array()));
1253
  self::$settings->setGlobalOption('disable_cookies', (isset($_POST['wp-piwik_disable_cookies'])?$_POST['wp-piwik_disable_cookies']:false));
1254
  self::$settings->setOption('tracking_code', $this->callPiwikAPI('SitesManager.getJavascriptTag'));
1447
  self::$settings = new WP_Piwik_Settings(self::$logger);
1448
  }
1449
 
1450
+ private function subClassConfig() {
1451
+ return array(
1452
+ 'wp_piwik' => $this,
1453
+ 'logger' => self::$logger,
1454
+ 'settings' => self::$settings
1455
+ );
1456
+ }
1457
  }
1458
 
1459
  }