#84481add missing "HTTP/1.1 308 Permanent Redirect" constant to HttpUtility
Description
In \TYPO3\CMS\Core\Utility\HttpUtility there are various HTTP status-headers defined as class-constants. This includes those for HTTP-redirects. I’m missing the “HTTP/1.1 308 Permanent Redirect” header here. Therefore I’ll prepare a PR for TYPO3.CMS’ master-branch to include this header as a class constant in the class mentioned above.
Research Information
The main difference to the well known “HTTP/1.1 301 Moved Permanently” header is, that 308 forces the client (aka Browser) to follow the redirect using the same protocol as the initial request. So for example with 308 a GET request must be followed with a GET request and a POST request must be followed with a POST request to the new location. With 301 status a POST request will be followed using a GET request to the new location.
The permanent redirect is defined here: According to Mozilla’s research (as well as my biased experience) it is supported by all browsers. A compact and profound description of the HTTP redirect-related headers, can be found on Stackoverflow.My Conclusion
Adding this header to the utility will not harm existing installations or anything at al.
Reviews 6
- TYPO3_8-7 56563[TASK] Streamline HTTP Response codes
- main 56562[TASK] Streamline HTTP Response codes
- TYPO3_8-7 56560[TASK] Add missing HTTP status code presets for PSR-7 responses
- main 56375[TASK] Add missing HTTP status code presets for PSR-7 responses
- TYPO3_8-7 56367[TASK] add missing "HTTP/1.1 308 Permanent Redirect" to HttpUtility
- main 56364[TASK] add missing "HTTP/1.1 308 Permanent Redirect" to HttpUtility