#9297 closed enhancement (fixed)
Updated List of HTTP status codes for wp_header_to_desc
Reported by: | Askapache | Owned by: | Askapache |
---|---|---|---|
Milestone: | 2.8 | Priority: | low |
Severity: | trivial | Version: | 2.8 |
Component: | HTTP API | Keywords: | has-patch, tested |
Focuses: | Cc: |
Description
Updated the list of HTTP Status Code Header Descriptions stored in the global variable $wp_header_to_desc used by the functions status_header and get_status_header_desc to include a few missing codes for 100% compliance with HTTP 1.1 protocol.
Reference
- IANA Hypertext Transfer Protocol (HTTP) Status Code Registry, Oct 17, 2007
- AskApache - 57 HTTP Status Codes, Jan 4, 2008
- Transparent Content Negotiation in HTTP, RFC 2295, March 1998.
- HTTP Extensions for Distributed Authoring -- WEBDAV, RFC 2518, February 1999.
- Hypertext Transfer Protocol -- HTTP/1.1, RFC 2616, June 1999.
- An HTTP Extension Framework, RFC 2774, February 2000.
- Upgrading to TLS Within HTTP/1.1, RFC 2817, May 2000.
- Delta encoding in HTTP, RFC 3229, January 2002.
- HTTP Extensions for Web Distributed Authoring and Versioning, RFC 4918, June 2007.
Attachments (1)
Change History (8)
#4
@
14 years ago
It's nice to have HTTP 1.1 compability, but that function is used for responses to HTTP 1.0 requests as well. I opened a new ticket because of that: #13940.
#5
@
14 years ago
Another flaw with this patch:
There is no 306 status code in HTTP 1.1. More details in section 10.3.7 306 (Unused):
The 306 status code was used in a previous version of the
specification, is no longer used, and the code is reserved.
So this function MUST return an empty string for 306 for both HTTP 1.0 and HTTP 1.1 (that's the two HTTP versions wordpress currently supports).
The previous version was an Internet-Draft by Josh Cohen from Netscape Communications Corp. dated 5 December 1996 and entitled "HTTP/1.1 305 and 306 Response Codes", filename <draft-cohen-http-305-306-responses-00.txt>. It's a draft. It never made it into HTTP 1.1 and it never was in HTTP 1.0.
I will not re-open this ticket because it's for an older version. I put this information here for documentation purposes.
There are other Headers from HTTP 1.1 extenstions like WEBDAV that I should go through as well. Let's see what that turns out.
functions.php.diff - update for $wp_header_to_desc