Is this in CFMX? This won't work in CF5 or earlier. They don't
recognize \d as digits.
--Ben
Matt Robertson wrote:
> I'm trying to use this code and it keeps throwing out the string
> whether its valid or not. I know I'm doing something wrong but am a
> dilettante at best when it comes to regexes. I also tried Ben Forta's
> phone regex out of his book with similarly bad results, so its
> definitely me doing something stupid here.
>
> ThisRegex="[\(.]?[2-9]\d\d[\).]?[ -]?[2-9]\d\d[-.]\d{4}";
>
> if (not REFind(ThisRegex, form.myphonefield) {
> ...
>
> What is my coffee-starved Monday morning brainlet missing here?
>
> --
> --Matt Robertson--
> MSB Designs, Inc.
> mysecretbase.com
>
[Todays Threads]
[This Message]
[Subscription]
[Fast Unsubscribe]
[User Settings]
[Donations and Support]
- Stupid telephone regex question Matt Robertson
- RE: Stupid telephone regex question Spike
- Re: Stupid telephone regex question Ben Doom
- Re: Stupid telephone regex question Ben Doom
- Re: Stupid telephone regex question Jochem van Dieten
- Re: Stupid telephone regex question Barney Boisvert
- Re: Stupid telephone regex question Matt Robertson
- Re: Stupid telephone regex question Barney Boisvert
- RE: Stupid telephone regex question Spike
- Re: Stupid telephone regex question Jochem van Dieten
- RE: Stupid telephone regex question Calder, Erick
- RE: Stupid telephone regex question Burns, John D
- Re: Stupid telephone regex question Matt Robertson
- RE: Stupid telephone regex question Pascal Peters