make html <title></title> configurable

Esse commit está contido em:
2019-10-02 21:40:58 +02:00
commit 4de7236aca
3 arquivos alterados com 13 adições e 4 exclusões

Ver Arquivo

@@ -44,9 +44,11 @@ Response Handler::errorResponse(std::string errortitle, std::string errormessage
return { status, error.render()};
}
std::string Handler::createPageTitle(std::string append)
std::string Handler::createPageTitle(std::string title)
{
return this->handlersConfig->wikiname + " - " + append; //TODO: we might wanna make the format configurable
Varreplacer replacer("{");
replacer.addKeyValue("title", title);
return replacer.parse(this->handlersConfig->page_title_template);
}
QueryOption Handler::queryOption(const Request &r) const