summaryrefslogtreecommitdiff
path: root/modules/statistics/statistics.tokens.inc
diff options
context:
space:
mode:
Diffstat (limited to 'modules/statistics/statistics.tokens.inc')
-rw-r--r--modules/statistics/statistics.tokens.inc12
1 files changed, 6 insertions, 6 deletions
diff --git a/modules/statistics/statistics.tokens.inc b/modules/statistics/statistics.tokens.inc
index 5261c4b16..1eb5b5d32 100644
--- a/modules/statistics/statistics.tokens.inc
+++ b/modules/statistics/statistics.tokens.inc
@@ -10,11 +10,11 @@
* Implements hook_token_info().
*/
function statistics_token_info() {
- $node['views'] = array(
+ $node['total-count'] = array(
'name' => t("Number of views"),
'description' => t("The number of visitors who have read the node."),
);
- $node['day-views'] = array(
+ $node['day-count'] = array(
'name' => t("Views today"),
'description' => t("The number of visitors who have read the node today."),
);
@@ -40,13 +40,13 @@ function statistics_tokens($type, $tokens, array $data = array(), array $options
$node = $data['node'];
foreach ($tokens as $name => $original) {
- if ($name == 'views') {
+ if ($name == 'total-count') {
$statistics = statistics_get($node->nid);
- $replacements[$original] = $statistics['totalviews'];
+ $replacements[$original] = $statistics['totalcount'];
}
- elseif ($name == 'views-today') {
+ elseif ($name == 'day-count') {
$statistics = statistics_get($node->nid);
- $replacements[$original] = $statistics['dayviews'];
+ $replacements[$original] = $statistics['daycount'];
}
elseif ($name == 'last-view') {
$statistics = statistics_get($node->nid);