Commit 23d7f880 authored by Robert Lyon's avatar Robert Lyon

Allowing visit stats to display on microheaders view (Bug #1395627)

Also pluralising the lang string

Change-Id: Ib98b5d4809d4c8a7dca30ccc0f735e9bdcb078de
Signed-off-by: Robert Lyon's avatarRobert Lyon <robertl@catalyst.net.nz>
parent 32279679
...@@ -134,7 +134,10 @@ $string['viewunobjectionablesubject'] = 'Page %s was marked as not objectionable ...@@ -134,7 +134,10 @@ $string['viewunobjectionablesubject'] = 'Page %s was marked as not objectionable
$string['viewunobjectionablebody'] = '%s has looked at %s by %s and marked it as no longer containing objectionable material.'; $string['viewunobjectionablebody'] = '%s has looked at %s by %s and marked it as no longer containing objectionable material.';
$string['updatewatchlistfailed'] = 'Update of watchlist failed'; $string['updatewatchlistfailed'] = 'Update of watchlist failed';
$string['watchlistupdated'] = 'Your watchlist has been updated.'; $string['watchlistupdated'] = 'Your watchlist has been updated.';
$string['viewvisitcount'] = '%d page visit(s) from %s to %s'; $string['viewvisitcount'] = array(
0 => '%d page visit from %s to %s',
1 => '%d page visits from %s to %s',
);
$string['profilenotshared'] = 'Full access to this user profile is restricted.'; $string['profilenotshared'] = 'Full access to this user profile is restricted.';
$string['friend'] = 'Friend'; $string['friend'] = 'Friend';
......
...@@ -345,7 +345,7 @@ if ($view->is_anonymous()) { ...@@ -345,7 +345,7 @@ if ($view->is_anonymous()) {
$titletext = ($collection && $shownav) ? hsc($collection->get('name')) : $view->display_title(true, false, false); $titletext = ($collection && $shownav) ? hsc($collection->get('name')) : $view->display_title(true, false, false);
$smarty->assign('visitstring', $view->visit_message());
if (get_config('viewmicroheaders')) { if (get_config('viewmicroheaders')) {
$smarty->assign('microheaders', true); $smarty->assign('microheaders', true);
...@@ -383,10 +383,8 @@ if (get_config('viewmicroheaders')) { ...@@ -383,10 +383,8 @@ if (get_config('viewmicroheaders')) {
} }
$smarty->assign('microheaderlinks', $microheaderlinks); $smarty->assign('microheaderlinks', $microheaderlinks);
} }
} }
else if ($can_edit) { else if ($can_edit) {
$smarty->assign('visitstring', $view->visit_message());
$smarty->assign('editurl', get_config('wwwroot') . 'view/blocks.php?id=' . $viewid . ($new ? '&new=1' : '')); $smarty->assign('editurl', get_config('wwwroot') . 'view/blocks.php?id=' . $viewid . ($new ? '&new=1' : ''));
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment