diff --git a/src/base/Application.cpp b/src/base/Application.cpp index cb67814..f05e996 100644 --- a/src/base/Application.cpp +++ b/src/base/Application.cpp @@ -192,6 +192,14 @@ void Application::initWebServer(ESP8266WebServer &server, bool &shouldReboot, bo server.sendHeader(F("Content-Encoding"), F("gzip")); server.send_P(200, PSTR("text/html"), getHTMLContent(fw), getHTMLContentSize(fw)); }); + // HTML mn handler + sprintf_P(url, PSTR("/mn%c.html"), _appId); + server.on(url, HTTP_GET, [this, &server]() + { + server.keepAlive(false); + server.sendHeader(F("Content-Encoding"), F("gzip")); + server.send_P(200, PSTR("text/html"), getHTMLContent(mn), getHTMLContentSize(mn)); }); + // HTML discover handler sprintf_P(url, PSTR("/discover%c.html"), _appId); server.on(url, HTTP_GET, [this, &server]() @@ -288,4 +296,4 @@ void Application::run() #endif appRun(); -} \ No newline at end of file +} diff --git a/src/base/Application.h b/src/base/Application.h index 4edb497..07fa2a5 100644 --- a/src/base/Application.h +++ b/src/base/Application.h @@ -19,6 +19,7 @@ class Application status, config, fw, + mn, discover } WebPageForPlaceHolder; @@ -70,4 +71,4 @@ class Application void run(); }; -#endif \ No newline at end of file +#endif diff --git a/src/base/Core.cpp b/src/base/Core.cpp index 0b3593b..d6409b9 100644 --- a/src/base/Core.cpp +++ b/src/base/Core.cpp @@ -51,6 +51,9 @@ const PROGMEM char *Core::getHTMLContent(WebPageForPlaceHolder wp) case fw: return fw0htmlgz; break; + case mn: + return mn0htmlgz; + break; case discover: return discover0htmlgz; break; @@ -70,6 +73,9 @@ size_t Core::getHTMLContentSize(WebPageForPlaceHolder wp) case fw: return sizeof(fw0htmlgz); break; + case mn: + return sizeof(mn0htmlgz); + break; case discover: return sizeof(discover0htmlgz); break; @@ -278,4 +284,4 @@ void Core::appInitWebServer(ESP8266WebServer &server, bool &shouldReboot, bool & { server.keepAlive(false); server.send(404); }); -} \ No newline at end of file +} diff --git a/src/base/Core.h b/src/base/Core.h index 1d8d030..42ba44a 100644 --- a/src/base/Core.h +++ b/src/base/Core.h @@ -10,6 +10,7 @@ #include "data/status0.html.gz.h" #include "data/config0.html.gz.h" #include "data/fw0.html.gz.h" +#include "data/mn0.html.gz.h" #include "data/discover0.html.gz.h" class Core : public Application @@ -30,4 +31,4 @@ class Core : public Application Core(char appId, String fileName) : Application(appId, fileName) {} }; -#endif \ No newline at end of file +#endif diff --git a/src/base/data/index.html b/src/base/data/index.html index f1af9a0..c19213e 100644 --- a/src/base/data/index.html +++ b/src/base/data/index.html @@ -48,6 +48,7 @@ class="pure-menu-link">Status