Commit d5c3c43c authored by jan.koester's avatar jan.koester
Browse files

inlined css & brotlie support fot html

parent a43972a8
Loading
Loading
Loading
Loading
+1 −2
Changes for data/template/default/index.html: 1 added line, 2 removed lines.
Original line number Diff line number Diff line
@@ -6,8 +6,7 @@
       <meta name="robots" content="all" >
       <meta charset="utf-8">   
       <meta name="viewport" content="width=device-width, initial-scale=1.0" >
       <link rel="stylesheet" href="${PREFIX}/theme/public/reset.css">
       <link rel="stylesheet" href="${PREFIX}/theme/public/style.css?v=16">
       <style>${RESET_CSS}${STYLE_CSS}</style>
       <link rel="icon" type="image/x-icon" href="${PREFIX}/theme/public/favicon.ico">
    </head>
    <body>
+1 −2
Changes for data/template/default/mobile.html: 1 added line, 2 removed lines.
Original line number Diff line number Diff line
@@ -6,8 +6,7 @@
    <meta name="robots" content="all" />
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <link rel="stylesheet" href="${PREFIX}/theme/public/reset.css">
    <link rel="stylesheet" href="${PREFIX}/theme/public/mstyle.css">
    <style>${RESET_CSS}${MSTYLE_CSS}</style>
    <link rel="icon" type="image/x-icon" href="${prefix}/theme/public/favicon.ico">
    </head>
    <body>
+2 −1
Changes for plugins/contact/contact.cpp: 2 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -45,6 +45,7 @@
#include <mail.h>
#include <blogi.h>
#include <i18n.h>
#include <compress.h>

#include <json-c/json.h>

@@ -157,7 +158,7 @@ namespace blogi {
            libhttppp::HttpResponse curres;
            curres.setContentType("text/html");
            curres.setState(HTTP200);
            curres.send(req, out.c_str(),out.length());
            sendCompressed(req, curres, out.c_str(),out.length());
            return true;

        };
+7 −6
Changes for plugins/content/content.cpp: 7 added lines, 6 removed lines.
Original line number Diff line number Diff line
@@ -47,6 +47,7 @@
#include <plugin.h>
#include <session.h>
#include <i18n.h>
#include <compress.h>

#define SITELIMIT 10

@@ -134,7 +135,7 @@ namespace blogi {
                libhttppp::HttpResponse resp;
                resp.setState(HTTP200);
                resp.setContentType("text/html");
                resp.send(curreq,out.c_str(),out.length());
                sendCompressed(curreq,resp,out.c_str(),out.length());

                return;
            }
@@ -212,7 +213,7 @@ namespace blogi {
            libhttppp::HttpResponse resp;
            resp.setState(HTTP200);
            resp.setContentType("text/html");
            resp.send(curreq,out.c_str(),out.length());
            sendCompressed(curreq,resp,out.c_str(),out.length());
        };

        void contentPage(const int tid,libhttppp::HttpRequest& curreq,libhtmlpp::HtmlElement &page,const std::string &sessionid) {
@@ -274,7 +275,7 @@ namespace blogi {
            libhttppp::HttpResponse resp;
            resp.setState(HTTP200);
            resp.setContentType("text/html");
            resp.send(curreq,out.c_str(),out.length());
            sendCompressed(curreq,resp,out.c_str(),out.length());
        };

        void addPostPage(const int tid,libhttppp::HttpRequest &curreq,libhtmlpp::HtmlElement &page,const std::string &sessionid){
@@ -446,7 +447,7 @@ namespace blogi {
            libhttppp::HttpResponse resp;
            resp.setState(HTTP200);
            resp.setContentType("text/html");
            resp.send(curreq,out.c_str(),out.length());
            sendCompressed(curreq,resp,out.c_str(),out.length());
        }

        void delPostPage(const int tid,libhttppp::HttpRequest& curreq,libhtmlpp::HtmlElement &page,const std::string &sessionid) {
@@ -498,7 +499,7 @@ namespace blogi {
            libhttppp::HttpResponse resp;
            resp.setState(HTTP200);
            resp.setContentType("text/html");
            resp.send(curreq,out.data(),out.length());
            sendCompressed(curreq,resp,out.c_str(),out.length());

        }

@@ -702,7 +703,7 @@ namespace blogi {
            libhttppp::HttpResponse resp;
            resp.setState(HTTP200);
            resp.setContentType("text/html");
            resp.send(curreq,out.c_str(),out.length());
            sendCompressed(curreq,resp,out.c_str(),out.length());
        }

        const std::string getName(){
+2 −1
Changes for plugins/gameinfo/gameinfo.cpp: 2 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -42,6 +42,7 @@
#include <theme.h>
#include <conf.h>
#include <i18n.h>
#include <compress.h>
#include <mutex>

#ifdef Windows
@@ -384,7 +385,7 @@ namespace blogi {
            libhttppp::HttpResponse resp;
            resp.setState(HTTP200);
            resp.setContentType("text/html");
            resp.send(req,out.c_str(),out.length());
            sendCompressed(req,resp,out.c_str(),out.length());
            return true;

        }
Loading