[BUGFIX] No double htmlspecialchars for filemount select 70/25770/2
authorAlexander Stehlik <alexander.stehlik@googlemail.com>
Sat, 30 Nov 2013 00:03:34 +0000 (01:03 +0100)
committerMarkus Klein <klein.t3@mfc-linz.at>
Fri, 13 Dec 2013 08:35:59 +0000 (09:35 +0100)
Since the labels and values of select items are run through
htmlspecialchars by the FormEngine there is no need to use
htmlspecialchars in the renderTceformsSelectDropdown() method which
generates the select items for the filemount Backend form.

The current code will htmlencode the select value twice which results
in a htmlencoded value in the database which causes problems with
directory names that contain special characters.

Resolves: #54027
Releases: 6.2, 6.1, 6.0
Change-Id: I7ec8262f6c3d20879cde0679636a6a8e5c1d19cd
Reviewed-on: https://review.typo3.org/25770
Reviewed-by: Helmut Hummel
Tested-by: Helmut Hummel
Reviewed-by: Oliver Klee
Reviewed-by: Markus Klein
Tested-by: Markus Klein
typo3/sysext/core/Classes/Resource/Service/UserFileMountService.php

index 53bd908..46e5fe6 100644 (file)
@@ -66,8 +66,8 @@ class UserFileMountService {
                                $folderItems = $this->getSubfoldersForOptionList($rootLevelFolder);
                                foreach ($folderItems as $item) {
                                        $PA['items'][] = array(
-                                               htmlspecialchars($item->getIdentifier()),
-                                               htmlspecialchars($item->getIdentifier())
+                                               $item->getIdentifier(),
+                                               $item->getIdentifier()
                                        );
                                }
                        } else {