Bug #90135
closedGet correct site in PageContentErrorHandler
100%
Description
The \TYPO3\CMS\Core\Error\PageErrorHandler\PageContentErrorHandler
class accepts the "errorContentSource" property for defining a URL to point to when an error occurs. This URL can either be a fully-formed URI or a link in TYPO3 internal syntax (i.e. t3://page?uid=xxx
).
When trying to build the URL based on the latter, the \TYPO3\CMS\Core\Error\PageErrorHandler\PageContentErrorHandler
first tries to get the site information from the current request. If that fails, it tries to get the site by using the uid given in the "t3" syntax.
This is an issue in a particular case: a multi-site setup with a central error page. In this case, the site should be retrieved first using the given uid and fall back on the current site.
I think that this behaviour makes a lot more sense in general, since the uid given may not belong the current site anyway. It seems safer to take the page uid as a reference and fall back on the current site.
The setup to reproduce this error is a TYPO3 installation with at least two sites. The error page for the second site points to a page in the first site.
Updated by Francois Suter over 4 years ago
It's more complicated than this, because the language is gotten from the request and not from the site, so we have the wrong URL base...
I'll keep digging because I still feel like it should be possible to have cross-domain linking at this place like in the rest of TYPO3.
Updated by Gerrit Code Review over 4 years ago
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/62955
Updated by Gerrit Code Review over 4 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/62955
Updated by Gerrit Code Review over 4 years ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/62955
Updated by Gerrit Code Review over 4 years ago
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/62955
Updated by Gerrit Code Review over 4 years ago
Patch set 1 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/63465
Updated by Anonymous over 4 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 83c3be60dd72095b90ddd696964ed1dcedc13871.
Updated by Christian Eßl over 4 years ago
- Related to Bug #91013: Site Error Handling does not respect disabled SiteLanguages added