NodeJS_0011:nodejs重定向到一个链接或本地的页面的方法
1,
app.get('/NUP', function(req, res, next) {
var form = fs.readFileSync('public/NodeUP/index.html', { encoding: 'utf8' });
res.send(form);
// 重定向到百度
// res.redirect("https://www.baidu.com");
});
琥珀君的博客

浙公网安备 33010602011771号