Here’s yet another way (using a negative look-ahead):
^/(?!ignoreme|ignoreme2|ignoremeN)([a-z0-9]+)$
Note: There’s only one capturing expression: ([a-z0-9]+)
.
More Related Contents:
- Is it possible to escape regex metacharacters reliably with sed
- Regex: match everything but a specific pattern
- Regex lookahead, lookbehind and atomic groups
- Regular expression for duplicate words
- Regular Expression for alphanumeric and underscores
- RegEx to parse or validate Base64 data
- My regular expression matches too much. How can I tell it to match the smallest possible pattern? [duplicate]
- RE error: illegal byte sequence on Mac OS X
- How do I include negative decimal numbers in this regular expression?
- Is there something like a counter variable in regular expression replace?
- Regular Expression for extracting text from an RTF string
- Why are regular expressions so controversial? [closed]
- What’s the Time Complexity of Average Regex algorithms?
- Regex to find 3 out of 4 conditions
- Escaped Periods In R Regular Expressions
- Regex to get the words after matching string [duplicate]
- Add slash to the end of every url (need rewrite rule for nginx)
- Does lookbehind work in sed?
- Lua pattern matching vs. regular expressions
- R split on delimiter (split) keep the delimiter (split)
- hive regexp_extract weirdness
- Google Sheets Formula for Extracting Domain From Website?
- Does \w match all alphanumeric characters defined in the Unicode standard?
- Matching an optional substring in a regex
- Invert match with regexp [duplicate]
- Replace string only once with php preg_replace
- Regex Letters, Numbers, Dashes, and Underscores
- How to replace only part of found text?
- Can I use an OR in regex without capturing what’s enclosed?
- How to make “grep” read patterns from a file?