in reply to Improving my regex skills and a few questions.

You've mistaken the x modifier: Memorize "eXpressive", meaning that you can use whitespace and even comments within a regex without impact on the pattern.
/ f # this matches "foo" o # and nothing else o /x

Replies are listed 'Best First'.
Re: Re: Improving my regex skills and a few questions.
by BrowserUk (Patriarch) on Aug 27, 2002 at 07:55 UTC

    Thanks Django! I actually saw your post last night (or rather earlier this morning my time) when you posted it. It immediately explained all my /x problems... instead of reading the description, I'd been blithely scanned over it thinking I knew what it meant.

    It also made me realise that I shouldn't try and code when I'm dog tired, and went to bed embarassed. Is that an an excuse? Probably.

    Now I have read it, I see exactly why it doesn't and couldn't work that way. Thanks.

    Ah well. Probably gave more people a good laugh than some of my puns:)


    What's this about a "crooked mitre"? I'm good at woodwork!