[BUGFIX] InlineElement: Make file extension check case insensitive 89/38389/3
authorMichael Oehlhof <typo3@oehlhof.de>
Tue, 31 Mar 2015 19:45:58 +0000 (21:45 +0200)
committerMarkus Klein <klein.t3@reelworx.at>
Wed, 1 Apr 2015 20:49:00 +0000 (22:49 +0200)
Using an inline element and trying to reference a file with an uppercase
(allowed) file extension does not show an error now.

Resolves: #66167
Releases: master, 6.2
Change-Id: I1da5869f4b1b9543e6afe270bdd3e5bac47b9258
Reviewed-on: http://review.typo3.org/38389
Reviewed-by: Frans Saris <franssaris@gmail.com>
Tested-by: Frans Saris <franssaris@gmail.com>
Reviewed-by: Markus Klein <klein.t3@reelworx.at>
Tested-by: Markus Klein <klein.t3@reelworx.at>
typo3/sysext/backend/Classes/Form/Element/InlineElement.php

index 9368a9c..6b8ed17 100644 (file)
@@ -1387,7 +1387,7 @@ class InlineElement {
                                $selectorConfiguration['PA']['fieldConf']['config']['appearance']['elementBrowserAllowed'],
                                TRUE
                        );
-                       if (!in_array($fileRecord['extension'], $allowedFileExtensions, TRUE)) {
+                       if (!in_array(strtolower($fileRecord['extension']), $allowedFileExtensions, TRUE)) {
                                return FALSE;
                        }
                }