gpt4 book ai didi

http - 其他 HTTP 方法是否可以接受 HTTP 303?

转载 作者:可可西里 更新时间:2023-11-01 15:19:44 29 4
gpt4 key购买 nike

RESTful Web Services鼓励使用 HTTP 303将客户端重定向到资源的规范表示。它仅在 HTTP GET 的上下文中讨论主题。

这是否也适用于其他 HTTP 方法?如果客户端尝试对非规范 URI 执行 HTTP PUTDELETE,是否可以接受(和/或建议)返回 HTTP 303?最佳做法是什么?为什么?

最佳答案

This status code is generally applicable to any HTTP method. It is primarily used to allow the output of a POST action to redirect the user agent to a selected resource, since doing so provides the information corresponding to the POST response in a form that can be separately identified, bookmarked, and cached independent of the original request.

来源:https://datatracker.ietf.org/doc/html/draft-ietf-httpbis-p2-semantics-21#section-7.4.4

关于http - 其他 HTTP 方法是否可以接受 HTTP 303?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13635181/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com