a guest Aug 16th, 2018 64 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- 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