diff --git a/blocktopmenu.php b/blocktopmenu.php index 1230a04..af0622d 100644 --- a/blocktopmenu.php +++ b/blocktopmenu.php @@ -608,8 +608,13 @@ private function generateCategoriesMenu($categories, $is_children = 0) else $link = $this->context->link->getPageLink('index'); - $html .= 'page_name == 'category' - && (int)Tools::getValue('id_category') == (int)$category['id_category']) ? ' class="sfHoverForce"' : '').'>'; + $li_classes = array('category'.(int)$category['id_category']); + + if ($this->page_name == 'category' && (int)Tools::getValue('id_category') == (int)$category['id_category']) + $li_classes[] = 'sfHoverForce'; + + $html .= ''; + $html .= ''.$category['name'].''; if (isset($category['children']) && !empty($category['children']))