[thelist] CF: Regex Help
Frank
lists at frankmarion.com
Thu Jul 17 23:34:38 CDT 2003
At 09:18 AM 2003-07-18 +1000, you wrote:
>Which version of CF are you using? I'm looking at the Docs for MX, and
>they state:
4.5sp2. My experience is that the regex engine seems to work consistently
across all versions.
>'.' is not an end of line for a regex
Correct, that was mis-statement on my part. I don't believe the including
end-of-line with the dot character is a good choice. It's precisely
because it queers what should be a simple solution like this one.
The original question is, how do I edit my regex to match the pattern that
does not end with \r or \n?
([\.a-zA-Z0-9_-]+)([^\.]{2})\.(co)[^m\.]
Try the following in studio: at line 1 char one, paste the following
domain.uk.co
hotmail.com
smith.co
abc.co <- Terminate the document here. do NOT add a line break.
Right now, the above only matches "smith.co" (there's a line break at the
end). No line break, no match. "abc.co" should not match. Therefor if I
pass it a variables such as "domain.co", there's no line break, no match.
--
Frank Marion lists at frankmarion.com Keep the signal high.
More information about the thelist
mailing list