How would I write a regular expression that matches any URL containing the segment "articles" followed by any other segment, but does NOT match URLs with the segment "articles-main"?
So it would match these:
www.mysite.com/articles
www.mysite.com/articles/tinman
But not these:
www.mysite.com/articles-main
www.mysite.com/articles-main/tinman
This is for use in ExpressionEngine if it matters.
Use a so called negative lookahead:
or more precisely: