diff --git a/index.php b/index.php index e3af45f10..67ada7be2 100644 --- a/index.php +++ b/index.php @@ -110,11 +110,9 @@ $template->assign('U_CANONICAL', $canonical_url); //-------------------------------------------------------------- page title $title = $page['title']; $template_title = $page['section_title']; -if (count($page['items']) > 0) -{ - $template_title.= ' ['.count($page['items']).']'; -} +$nb_items = count($page['items']); $template->assign('TITLE', $template_title); +$template->assign('NB_ITEMS', $nb_items); //-------------------------------------------------------------- menubar include( PHPWG_ROOT_PATH.'include/menubar.inc.php'); diff --git a/themes/default/template/index.tpl b/themes/default/template/index.tpl index 81802b16f..d1411d2f7 100644 --- a/themes/default/template/index.tpl +++ b/themes/default/template/index.tpl @@ -97,7 +97,7 @@ {if !empty($PLUGIN_INDEX_ACTIONS)}{$PLUGIN_INDEX_ACTIONS}{/if} -

{$TITLE}

+

{$TITLE} {if $NB_ITEMS > 0}{$NB_ITEMS}{/if}

{if isset($chronology_views)}
{'View'|@translate}: diff --git a/themes/default/template/menubar_categories.tpl b/themes/default/template/menubar_categories.tpl index c3c5b1c02..6000e756f 100644 --- a/themes/default/template/menubar_categories.tpl +++ b/themes/default/template/menubar_categories.tpl @@ -19,7 +19,7 @@
  • {$cat.NAME} {if $cat.count_images > 0} - [{$cat.count_images}] + {$cat.count_images} {/if} {if !empty($cat.icon_ts)} (!) diff --git a/themes/default/theme.css b/themes/default/theme.css index 5a438be9c..3468e3992 100644 --- a/themes/default/theme.css +++ b/themes/default/theme.css @@ -113,6 +113,14 @@ padding:0 25px; } +.badge::before { + content: '['; +} + +.badge::after { + content: ']'; +} + /* category and tag results paragraphs on a quick search */ .search_results { font-size: 16px;