From 02f8414f11db6299c07236cf472eb08bca31180e Mon Sep 17 00:00:00 2001 From: Elmar Hinz Date: Wed, 17 May 2017 17:46:55 +0200 Subject: [PATCH] [BUGFIX] Keep MP parameters upon redirect of overlay When a mount point, that is overlayed, redirects to the overlaying page, don't throw away existing mount point parameters. The other mount point parameters may specify a mount point upwards in the root line. Under normal circumstances the page should not be linked at all. However a redirect is provided and as it is provided it should work as expected. Releases: master Resolves: #81251 Change-Id: I4cf830e5b24ebc9799e58f83d7787a726f92a3d4 Reviewed-on: https://review.typo3.org/52829 Tested-by: TYPO3com Reviewed-by: Susanne Moog Tested-by: Susanne Moog Reviewed-by: Benni Mack Tested-by: Benni Mack --- .../Classes/Controller/TypoScriptFrontendController.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php b/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php index 590d8f28a529..0e29f5dca992 100644 --- a/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php +++ b/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php @@ -1610,7 +1610,11 @@ protected function getPageAndRootline() . 'mounts a page which is not accessible (ID ' . $this->originalMountPointPage['mount_pid'] . ').'; throw new PageNotFoundException($message, 1402043263); } - $this->MP = $this->page['uid'] . '-' . $this->originalMountPointPage['uid']; + if ($this->MP === '') { + $this->MP = $this->page['uid'] . '-' . $this->originalMountPointPage['uid']; + } else { + $this->MP .= ',' . $this->page['uid'] . '-' . $this->originalMountPointPage['uid']; + } $this->id = $this->page['uid']; } // Gets the rootLine