Replies: 3 comments
-
|
Beta Was this translation helpful? Give feedback.
-
Do you want to:
1. is easy: app.use((req, res, next) => {
// redirect if id header is truthy
if (req.headers.id) res.redirect('https://...');
else next();
} 2. and 3. as far as I know are impossible. Redirections are described in RFC 9110 in section 15.4. Redirection 3xx. The RFC says (emphasis mine):
In general, the user agent (e.g. browser) sends the original request, but changes some necessary automatically generated headers (e.g. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
All reactions