Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
一种获取方式HTTP_REFERER,我们可以document.referrer在浏览器端使用javascript。但是我们如何在 NodeJS 中得到它呢?
HTTP_REFERER
document.referrer
你可以通过...
req.headers.referer
在...
var http = require('http'); server = http.createServer(function(req, res){ ... }