Field validation: avoid form...

User 187934 Photo


Senior Advisor
20,271 posts

I converted most of my inputs to regular expressions. This way I can control every aspect of what's being entered.:cool:
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 2582728 Photo


Registered User
48 posts

Definitely rusty at this and need to read a bit more, but it looks like:

/^[2-5][0-9]|[6][0-4]+$/

might do the trick, filtering: 20 through 59, or 60 through 64, netting me "20 through 64"...
User 187934 Photo


Senior Advisor
20,271 posts

You may run into a few problems with the reg expressions as there's a bug in their validation for certain values. CC should have this taken care of in the next release.
http://www.coffeecup.com/forums/web-for … pressions/
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 2582728 Photo


Registered User
48 posts

Thanks again Eric. Looks like the simple regex case I need works in WFB. I'm not going to make the change to the form just yet -- but it's good to have an alternate solution in my back pocket now. I don't want to second guess the client -- he may be enamored of the spinner in Chrome. But if he's willing to trade that for onblur regex validation, I can offer him that as the alternative.

Think I'm set now -- thanks again!

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.