View Full Version : TextField Validation Allows Blanks
FuryVII
26 Sep 2007, 11:02 AM
allowBlank returns true if a user puts a single space. How can I validate a field after applying trim (or something similiar)?
Thanks.
FuryVII
26 Sep 2007, 11:08 AM
I figured out a way to do it, but its pretty cumbersome. Before the form is checked as valid or not, I get the form fields value trim and then reset the value.
It works, but I was wondering if the functionality exists within Ext already.
otatop
3 Dec 2008, 9:20 AM
Just add the following regular expresion to validate that there is something other than spaces in the value.
regex:/[^\s]/,
Powered by vBulletin® Version 4.1.5 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.