PCB lives now in its own git repo https://git.la10cy.net/DeltaLima/CanGrow-12V-PCB
26 lines
636 B
C
26 lines
636 B
C
/*
|
|
* 404 error page begins
|
|
*/
|
|
|
|
// 404 page is a good page template btw
|
|
const char Page_404_HTML[] PROGMEM = R"EOF(%HEADER%
|
|
<div class='warnmsg'><h1>❗ ️ 404 - not found</h1></div>
|
|
%FOOTER% )EOF";
|
|
|
|
/* processor */
|
|
String Proc_WebPage_404(const String& var) {
|
|
if(TestHeaderFooter(var)) {
|
|
return AddHeaderFooter(var);
|
|
} else {
|
|
return String();
|
|
}
|
|
}
|
|
|
|
// https://github.com/mathieucarbou/ESPAsyncWebServer/blob/main/examples/SimpleServer/SimpleServer.ino
|
|
void WebserverNotFound(AsyncWebServerRequest* request) {
|
|
request->send_P(404, TEXT_HTML, Page_404_HTML, Proc_WebPage_404);
|
|
}
|
|
|
|
/*
|
|
* 404 error page ends
|
|
*/
|