[BUGFIX] ElementBrowser: Fix JS error after folder creation 16/36916/2
authorNicole Cordes <typo3@cordes.co>
Sat, 14 Feb 2015 19:45:42 +0000 (20:45 +0100)
committerWouter Wolters <typo3@wouterwolters.nl>
Sat, 14 Feb 2015 23:10:44 +0000 (00:10 +0100)
Add missing parameters in returnUrl to prevent a Javascript error
blocking all further Javascript execution.

Releases: master, 6.2
Resolves: #65074
Change-Id: I34cb27eaf9678b6bab1297b579fec3a6d5385149
Reviewed-on: http://review.typo3.org/36916
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
typo3/sysext/recordlist/Classes/Browser/ElementBrowser.php

index 4e7811f..3bbb3a9 100644 (file)
@@ -2525,7 +2525,8 @@ class ElementBrowser {
                // Make footer of upload form, including the submit button:
                $redirectValue = $this->getThisScript() . 'act=' . $this->act . '&mode=' . $this->mode
                        . '&expandFolder=' . rawurlencode($folderObject->getCombinedIdentifier())
-                       . '&bparams=' . rawurlencode($this->bparams);
+                       . '&bparams=' . rawurlencode($this->bparams)
+                       . (is_array($this->P) ? GeneralUtility::implodeArrayForUrl('P', $this->P) : '');
                $code .= '<input type="hidden" name="redirect" value="' . htmlspecialchars($redirectValue) . '" />'
                        . \TYPO3\CMS\Backend\Form\FormEngine::getHiddenTokenField('tceAction')
                        . '<input type="submit" name="submit" value="'