diff --git a/components/com_content/views/category/view.html.php b/components/com_content/views/category/view.html.php index 8bfed34690abb..08cc5946dce19 100644 --- a/components/com_content/views/category/view.html.php +++ b/components/com_content/views/category/view.html.php @@ -184,12 +184,21 @@ public function display($tpl = null) // we need to get it from the menu item itself $menu = $menus->getActive(); - if ($menu) + if ($menu + && $menu->component == 'com_content' + && isset($menu->query['view'], $menu->query['id']) + && $menu->query['view'] == 'category' + && $menu->query['id'] == $this->category->id) { $this->params->def('page_heading', $this->params->get('page_title', $menu->title)); + $title = $this->params->get('page_title', $menu->title); + } + else + { + $this->params->def('page_heading', $this->category->title); + $title = $this->category->title; + $this->params->set('page_title', $title); } - - $title = $this->params->get('page_title', ''); $id = (int) @$menu->query['id'];