Chris74 Posted September 2, 2013 Share Posted September 2, 2013 Hi can someone possibly let me know what I need to do here... 1. I created a standard text custom client field that is not a required field and I use the following validation string, which was specified by the instructions in a module I installed... /([0-9])+/ 2. A customer fills out the registration form, but leaves the field empty. 3. WHMCS produces the error on that field that the "value is not valid". If the customer enters a set of numbers into the field, it submits correctly. This field is used by a module I installed and the instructions specify that the above validation string must be used. I don't really understand regular expressions. Is it simply that the expression does not allow for an empty string - so it produces an error because no number is provided? It's reasonable to assume that a customer may not want to fill out that field - so the validation needs to allow for it to be empty. Any idea how I can fix it? Your help would be greatly appreciated. 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted September 2, 2013 Share Posted September 2, 2013 I think it would be... /^(?:[0-9])$/ 0 Quote Link to comment Share on other sites More sharing options...
Chris74 Posted September 2, 2013 Author Share Posted September 2, 2013 I think it would be... /^(?:[0-9])$/ Yes, that works. Thanks again Brian! 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.