[BUGFIX] Fix invalid URL in EditDocumentController 38/38638/2
authorMarkus Klein <klein.t3@reelworx.at>
Sat, 11 Apr 2015 16:31:40 +0000 (18:31 +0200)
committerMarkus Klein <klein.t3@reelworx.at>
Sat, 11 Apr 2015 16:53:27 +0000 (18:53 +0200)
The form action generated in EditDocumentController now properly
resolves ? and & characters clashing together.

Releases: master
Resolves: #66382
Change-Id: I038e2179229cbe3a65dbc1731fd6db789c2d10f9
Reviewed-on: http://review.typo3.org/38638
Reviewed-by: Mathias Schreiber <mathias.schreiber@wmdb.de>
Tested-by: Mathias Schreiber <mathias.schreiber@wmdb.de>
Reviewed-by: Markus Klein <klein.t3@reelworx.at>
Tested-by: Markus Klein <klein.t3@reelworx.at>
typo3/sysext/backend/Classes/Controller/EditDocumentController.php

index a42da63..11961e9 100644 (file)
@@ -634,7 +634,7 @@ class EditDocumentController {
                $this->perms_clause = $GLOBALS['BE_USER']->getPagePermsClause(1);
                // Set other internal variables:
                $this->R_URL_getvars['returnUrl'] = $this->retUrl;
-               $this->R_URI = $this->R_URL_parts['path'] . '?' . GeneralUtility::implodeArrayForUrl('', $this->R_URL_getvars);
+               $this->R_URI = $this->R_URL_parts['path'] . '?' . ltrim(GeneralUtility::implodeArrayForUrl('', $this->R_URL_getvars), '&');
                // MENU-ITEMS:
                // If array, then it's a selector box menu
                // If empty string it's just a variable, that'll be saved.