in reply to How can I build regexp with "not" assertion?

This will probably work, depending on what pattern1 and pattern2 really are:
/ pattern1 (?:(?!pattern1).)* pattern2 (?:(?!pattern1).)* pattern1 /x

Replies are listed 'Best First'.
Re^2: How can I build regexp with "not" assertion?
by putnik (Novice) on Feb 22, 2008 at 14:09 UTC
    THANK YOU! THANK YOU! THANK YOU!
    It greatly work.
    Googd Luck!