This commit is contained in:
kogleee
2023-11-08 13:17:48 +03:00
commit 3dbd9654c2
136 changed files with 14736 additions and 0 deletions

18
task20/app.js Normal file
View File

@@ -0,0 +1,18 @@
const express = require('express');
const app = express();
// обработка запроса по адресу /about
app.get('/about', function (request, response) {
response.send('<h1>О сайте</h1>');
});
// обработка запроса по адресу /contact
app.use('/contact', function (request, response) {
response.send('<h1>Контакты</h1>');
});
// обработка запроса к корню веб-сайта
app.get('/l*li', function (request, response) {
response.send('<h1>Главная страница</h1>');
});
app.listen(3000);