When you are looking a category or section, why no change the document title by the sections/category name?

Code: Select all
$title = $this->params->get('page_title', '');
if (empty($title) || (isset($title) && $title == '')) {
$title = $this->item->title; // category title
}
if (empty($title) || (isset($title) && $title == '')) {
$title = htmlspecialchars_decode($app->getCfg('sitename'));
} else if ($app->getCfg('sitename_pagetitles', 0)) {
$title = JText::sprintf('JPAGETITLE', htmlspecialchars_decode($app->getCfg('sitename')), $title);
}
$this->document->setTitle($title);