a guest Aug 16th, 2018 64 Never
- Regex lookaheads (or behinds) matching foo bar or bar foo
- /^(?=.*foo)(foo )?bar baz( foo)?$/
- /foo bar baz|bar baz foo/
- $foo = 'foo'
- $barbaz = 'bar baz'
- $regex = "($foo $barbaz)|($barbaz $foo)"
- (foo bar baz|bar baz foo)
- (foo (bar|baz)|(bar|baz) foo)
RAW Paste Data