How to do 404 page and under what circumstances jump to 404 page
仅有的幸福2017-05-16 13:39:55
How to implement
koa
app.use(async ctx => {
ctx.status = 404;
ctx.body = await readSmallFile('./404.html');
});
PHP中文网2017-05-16 13:39:55
Status code 404 means NOT FOUND
, probably
The address link is wrong;
The corresponding page cannot be found on the server;
Generally, you can design a separate page for 404; 404 not found
is just a friendly reminder to the user that the page cannot be accessed.