Indeed that is much simpler. I wish I'd thought of it :)
In reply to Re^3: conditional regex by BrowserUk in thread conditional regex by Anonymous Monk