summaryrefslogtreecommitdiffhomepage
path: root/plugins/weblog/weblog.cpp
diff options
context:
space:
mode:
authorRoland Reichwein <mail@reichwein.it>2020-05-01 14:36:51 +0200
committerRoland Reichwein <mail@reichwein.it>2020-05-01 14:36:51 +0200
commit3ee59ca3730aaaacb66ac26fed9fd1d72d033ae4 (patch)
tree75aef6b7a488e43d6ce3cb8ef1a23a3bf8d5a7c7 /plugins/weblog/weblog.cpp
parentc3612be4c3c51ccbe0e4ab27a9d7cf02e0ff3819 (diff)
Added style sheet
Diffstat (limited to 'plugins/weblog/weblog.cpp')
-rw-r--r--plugins/weblog/weblog.cpp14
1 files changed, 10 insertions, 4 deletions
diff --git a/plugins/weblog/weblog.cpp b/plugins/weblog/weblog.cpp
index 20c70b7..4ed468e 100644
--- a/plugins/weblog/weblog.cpp
+++ b/plugins/weblog/weblog.cpp
@@ -250,10 +250,13 @@ namespace {
, mContents(s)
, mHeader("<!DOCTYPE html><html><head>"
"<meta charset=\"utf-8\"/>"
+ "<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">"
"<title>" + GetRequestParam("WEBLOG_NAME") + "</title>"
"<meta name=\"keywords\" content=\"" + GetRequestParam("WEBLOG_KEYWORDS") + "\"/>"
- "</head><body>")
- , mFooter("<br/><br/><br/><a href=\"" + mGetRequestParam("plugin_path") + "/impressum.html\">Impressum, Datenschutzerklärung</a></body></html>")
+ "<link rel=\"shortcut icon\" href=\"" + mGetRequestParam("plugin_path") + "/favicon.ico\" type=\"image/x-icon\"/>"
+ "<link rel=\"stylesheet\" type=\"text/css\" href=\"" + mGetRequestParam("plugin_path") + "/blog.css\"/>"
+ "</head><body><div class=\"page\">")
+ , mFooter("<br/><br/><br/><div class=\"impressum\"><a href=\"" + mGetRequestParam("plugin_path") + "/impressum.html\">Impressum, Datenschutzerklärung</a></div></div></body></html>")
{
}
@@ -286,7 +289,8 @@ namespace {
for (const auto& article: list) {
std::string linkstart{"<a href=\"" + (link / article.path.filename()).string() + "/\">"};
std::string linkend{"</a>"};
- htmlPage += "<h2>"s + linkstart + article.subject + linkend + "</h2>"s + article.date + "<br/>"s;
+ htmlPage += "<h2>"s + linkstart + article.subject + linkend + "</h2>"s;
+ htmlPage += "<div class=\"date\">" + article.date + "</div>"s;
auto sv{shortVersion(article.path)};
if (sv.size()) {
@@ -327,7 +331,9 @@ namespace {
if (it != metaData.end() && it->second == "text/plain")
data = verbatimText(data);
- HtmlPage htmlPage{GetRequestParam, "<h1>"s + metaData.at("Subject") + "</h1>"s + metaData.at("Date") + "<br/><br/>"s + data};
+ HtmlPage htmlPage{GetRequestParam, "<h1>"s + metaData.at("Subject") + "</h1>"
+ "<div class=\"date\">" + metaData.at("Date") + "</div>"
+ "<br/><br/>"s + data};
return htmlPage;
} catch (const std::exception& ex) {