开发者

Http Headers: Redirected because not allowed?

What's the correct header to say 'you are not authenticated/authoriz开发者_StackOverflowed to access the content of this URL, so I'm redirecting you somewhere else (eg: login page)'.

Is it fine to just use a 302 ? Or maybe a 307 ?


401 is unauthorized, there is no unauthorized and redirection (301/307) in the same HTTP status.


I'd issue a 401 with a link in the body and a timed javascript redirect.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜