Feature #37561
Re-implement Accept Header / Content Negotiation support
Status: | Resolved | Start date: | 2012-05-29 | |
---|---|---|---|---|
Priority: | Should have | Due date: | ||
Assigned To: | Robert Lemke | % Done: | 100% |
|
Category: | Http | |||
Target version: | TYPO3 Flow Base Distribution - 1.1 beta 2 | |||
PHP Version: | 5.3 | Complexity: | medium | |
Has patch: | No |
Description
The older implementation is fairly limited to a single specific media type and also uses the old MIME terminology.
An improved implementation should be
- well integrated into the new HTTP support
- consider Quality Values while analyzing the Accept header
- use the new Internet Media Type terminology
- well tested
Related issues
Associated revisions
[!!!][FEATURE] Content Negotiation for Media Types
This improves the support for detecting the Media
Type (that is, "format" in an ActionRequest context)
based on the request's Accept header.
This implementation supports Quality Values and Media
Ranges as specified in RFC 2616.
The way to define the supported formats of a controller
has changed: Previously a class property $supportedFormats
contained a list of filename extensions which would be
supported. This property is not supported anymore.
Instead, controllers may now specify a list of IANA
Internet Media Types in a property $supportedMediaTypes.
The default setting for these supported media types
in ActionController is "text/html". You'll need to adjust
your controllers accordingly if you relied on the
$supportedFormats feature.
Also note that the format in ActionRequest is now NULL
by default. The ActionController makes sure to set the
correct format, but if you created your own ActionRequest
for a special purpose, you need to take care of setting
it yourself.
Change-Id: I7d753155aa72f41e3df85b076e8067bcbfe7ac04
Resolves: #37561
Releases: 1.1, 1.2
[!!!][FEATURE] Content Negotiation for Media Types
This improves the support for detecting the Media
Type (that is, "format" in an ActionRequest context)
based on the request's Accept header.
This implementation supports Quality Values and Media
Ranges as specified in RFC 2616.
The way to define the supported formats of a controller
has changed: Previously a class property $supportedFormats
contained a list of filename extensions which would be
supported. This property is not supported anymore.
Instead, controllers may now specify a list of IANA
Internet Media Types in a property $supportedMediaTypes.
The default setting for these supported media types
in ActionController is "text/html". You'll need to adjust
your controllers accordingly if you relied on the
$supportedFormats feature.
Also note that the format in ActionRequest is now NULL
by default. The ActionController makes sure to set the
correct format, but if you created your own ActionRequest
for a special purpose, you need to take care of setting
it yourself.
Change-Id: I7d753155aa72f41e3df85b076e8067bcbfe7ac04
Resolves: #37561
Releases: 1.1, 1.2
History
#1 Updated by Gerrit Code Review about 3 years ago
- Status changed from Accepted to Under Review
Patch set 1 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/11683
#2 Updated by Gerrit Code Review about 3 years ago
Patch set 2 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/11683
#3 Updated by Gerrit Code Review about 3 years ago
Patch set 3 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/11683
#4 Updated by Gerrit Code Review about 3 years ago
Patch set 4 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/11683
#5 Updated by Gerrit Code Review about 3 years ago
Patch set 5 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/11683
#6 Updated by Gerrit Code Review about 3 years ago
Patch set 6 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/11683
#7 Updated by Gerrit Code Review about 3 years ago
Patch set 7 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/11683
#8 Updated by Robert Lemke about 3 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 03b6d85916e46ed8b2e99bc549d7248957dca935.
#9 Updated by Gerrit Code Review about 3 years ago
- Status changed from Resolved to Under Review
Patch set 1 for branch FLOW3-1.1 has been pushed to the review server.
It is available at http://review.typo3.org/11727
#10 Updated by Gerrit Code Review about 3 years ago
Patch set 2 for branch FLOW3-1.1 has been pushed to the review server.
It is available at http://review.typo3.org/11727
#11 Updated by Gerrit Code Review about 3 years ago
Patch set 3 for branch FLOW3-1.1 has been pushed to the review server.
It is available at http://review.typo3.org/11727
#12 Updated by Gerrit Code Review about 3 years ago
Patch set 4 for branch FLOW3-1.1 has been pushed to the review server.
It is available at http://review.typo3.org/11727
#13 Updated by Robert Lemke about 3 years ago
- Status changed from Under Review to Resolved
Applied in changeset 29618c52b31a51acb1ddc4fb7796dfdab909cafe.