make html <title></title> configurable

Αυτή η υποβολή περιλαμβάνεται σε:
2019-10-02 21:40:58 +02:00
γονέας 7fc9c090ed
υποβολή 1c646fa165
3 αρχεία άλλαξαν με 14 προσθήκες και 4 διαγραφές

@ -43,9 +43,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