BioController/olStatic.txt
2025-03-10 19:31:28 -05:00

21 lines
442 B
Text
Executable file

void static_index(Request &req, Response &res) {
P(index) =
"<html>\n"
"<head>\n"
"<title>Hello World!</title>\n"
"</head>\n"
"<body>\n"
"<h1>Greetings middle earth!</h1>\n"
"</body>\n"
"</html>";
res.set("Content-Type", "text/html");
res.printP(index);
}
Router staticFileRouter;
Router * staticFiles() {
staticFileRouter.get("/", &static_index);
return &staticFileRouter;
}