Post Reply 
Your browser is no longer supported.
Jan. 15, 2015, 07:16 PM
Post: #17
RE: Your browser is no longer supported.
Oh, I'm not arguing that it should be the way I saw it, I'm just trying to understand how it works. What's being matched isn't very complex, but apparently my mind is wedded to particular ways of describing relationships and takes some training to think in other terms (or I'm just dense, lol).

(Jan. 15, 2015 05:50 AM)JJoe Wrote:  [] says match once
[]+ says blindly match all or nothing
[^/|]+ says blindly match anything that isn't a / or a | until there are no more OR nothing.

In "[^/|]" I was thinking that "|" was being used as a meta character that meant OR. Not true? If as you say, it's trying instead to avoid matching the characters "/" and "|", why isn't the escape character "\" used before the "|" ?

And the "or nothing" description is still confounding me. Going back to post #14, what specifically is in the "[^/]+" that indicates "or nothing" ?
According to the matching rules, the "+" supposedly "indicates a run of repeating characters." The example used says: [abc]+ would match a run of any characters "a","b",or "c" like "ababccba"
So, since there's no OR symbol "|" in that expression, I'm having trouble getting anything but "match a run of anything that's not a "/" "
Add Thank You Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Your browser is no longer supported. - zoltan - Jan. 15, 2015 07:16 PM

Forum Jump: