Skip to content
Snippets Groups Projects
Commit ecc1ffd0 authored by Helmut Hummel's avatar Helmut Hummel
Browse files

[BUGFIX] Send correct content type for cached Extbase actions

The setContentType method on TyposcripFrontendController
was introduced to allow Extbase plugins to change the
content-type header of the server http response.

However this currently only works, when the Extbase plugin
action is uncached. Once a plugin, that is rendered on a page
ist cached in page cache, the content type of subsequent
requests is always "text/html", because the value of the
contentType property is not stored in cache.

Storing this value into cache allows creating e.g.
Json APIs as Extbase Plugins, that can be fully cached
without adding hacks like modifying config.additionalHeaders

Resolves: #99373
Releases: main, 11.5
Change-Id: Ibf00c9438d8763ef9d32c6ad7d00a44d3137ba13
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/77269


Tested-by: default avatarcore-ci <typo3@b13.com>
Reviewed-by: default avatarHelmut Hummel <typo3@helhum.io>
Tested-by: default avatarHelmut Hummel <typo3@helhum.io>
parent ff7c2766
Branches
Tags
No related merge requests found
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment