mirror of
https://gitlab.com/MrFry/mrfrys-node-server
synced 2025-04-01 20:24:18 +02:00
Small website redesign
This commit is contained in:
parent
4370a1717c
commit
774ff64b36
2 changed files with 19 additions and 11 deletions
15
server.js
15
server.js
|
@ -34,7 +34,7 @@ var bodyParser = require('body-parser');
|
|||
const recivedFiles = "public/recivedfiles";
|
||||
const motdFile = "public/motd";
|
||||
const staticFile = "public/data/static";
|
||||
const dataFile = "public/data/data";
|
||||
const dataFile = "public/data.json";
|
||||
const countFile = "public/data/count";
|
||||
const manFile = "public/man.html";
|
||||
const simpOutFile = "public/simplified";
|
||||
|
@ -114,6 +114,19 @@ app.get('/static', function(req, res) {
|
|||
res.end();
|
||||
});
|
||||
|
||||
app.get('/legacy', function(req, res) {
|
||||
var f = utils.ReadFile(dataFile);
|
||||
var r = '<html><body bgcolor="#212127"><head><meta charset="UTF-8">';
|
||||
r += '<style>body { font: normal 14px Verdana; color: #999999;}</style>';
|
||||
var d = actions.LoadJSON(f).toString().split("\n");
|
||||
for (var i = 0; i < d.length; i++)
|
||||
r += d[i] + "</br>";
|
||||
r += '</head></body></html>';
|
||||
|
||||
res.write(r);
|
||||
res.end();
|
||||
});
|
||||
|
||||
app.post('/postfeedback', function(req, res) {
|
||||
res.redirect('back');
|
||||
newMessages += "\n" + req.body.message_field;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue