[BUGFIX] Filter out space char on client-side from alpha/num/alphanum/alphanum_x... 66/48066/5
authorNikola Stojiljkovic <nikola.stojiljkovic@essentialdots.com>
Tue, 10 May 2016 14:20:44 +0000 (17:20 +0300)
committerTymoteusz Motylewski <t.motylewski@gmail.com>
Tue, 10 May 2016 15:23:10 +0000 (17:23 +0200)
Resolves: #76125
Releases: master
Change-Id: I9d542a7a1a380a32f39f1c61f7cb4cf2d4b316b5
Reviewed-on: https://review.typo3.org/48066
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Tymoteusz Motylewski <t.motylewski@gmail.com>
Tested-by: Tymoteusz Motylewski <t.motylewski@gmail.com>
typo3/sysext/backend/Resources/Public/JavaScript/FormEngineValidation.js
typo3/sysext/backend/Resources/Public/JavaScript/jsfunc.evalfield.js
typo3/sysext/core/Tests/Acceptance/Backend/Formhandler/ElementsBasicCest.php

index 8408d90..89d1441 100644 (file)
@@ -402,7 +402,7 @@ define(['jquery', 'TYPO3/CMS/Backend/FormEngine'], function ($, FormEngine) {
                                                        special = 0;
                                                        break;
                                        }
-                                       if (alpha || num || theChar == ' ' || special) {
+                                       if (alpha || num || special) {
                                                newString += theChar;
                                        }
                                }
index d62fe62..111aed5 100644 (file)
@@ -97,7 +97,7 @@ function evalFunc_caseSwitch(type,inVal) {
                                        case "alpha":   num=0; special=0;               break;
                                        case "num":     alpha=0; special=0;             break;
                                }
-                               if (alpha || num || theChar==' ' || special) {
+                               if (alpha || num || special) {
                                        newString+=theChar;
                                }
                        }
index 9f2da7b..9720b91 100644 (file)
@@ -69,13 +69,13 @@ class ElementsBasicCest
             'input_4 eval=alpha' => [
                 [
                     'Kasper = TYPO3',
-                    'Kasper  TYPO',
+                    'KasperTYPO',
                 ],
             ],
             'input_5 eval=alphanum' => [
                 [
                     'Kasper = TYPO3',
-                    'Kasper  TYPO3',
+                    'KasperTYPO3',
                 ],
             ],
             'input_6 eval=date' => [