const express = require('express');
const axios = require('axios');
const app = express();
const port = 3000;
app.use(express.static('public'));
app.get('/fetch-website', async (req, res) => {
try {
const response = await axios.get('http://14.182.164.182:82/awp/control.html');
res.send(response.data);
} catch (error) {
console.error(error);
res.status(500).send('Internal Server Error');
}
});
app.listen(port, () => {
console.log(`Server is running at http://localhost:${port}`);
});
Web Widget
Nhận xét
Đăng nhận xét