The search page title is now more precise in case a scope is provided. re #34

This commit is contained in:
Sébastien Lucas 2013-10-06 18:08:26 +02:00
parent 065d9aeb98
commit 23129b9c9e
12 changed files with 61 additions and 2 deletions

View file

@ -673,9 +673,24 @@ class PageQueryResult extends Page
public function InitializeContent ()
{
global $config;
$this->title = str_format (localize ("search.result"), $this->query);
$scope = getURLParam ("scope");
switch ($scope) {
case self::SCOPE_AUTHOR :
$this->title = str_format (localize ("search.result.author"), $this->query);
break;
case self::SCOPE_TAG :
$this->title = str_format (localize ("search.result.tag"), $this->query);
break;
case self::SCOPE_SERIES :
$this->title = str_format (localize ("search.result.series"), $this->query);
break;
case self::SCOPE_BOOK :
$this->title = str_format (localize ("search.result.book"), $this->query);
break;
default:
$this->title = str_format (localize ("search.result"), $this->query);
}
$crit = "%" . $this->query . "%";
$bad = "QQQQQ";