We have this RedirectMatch rule to move clients on the SSL enabled site while maintaining the path they're trying to access:
Redirectmatch permanent (.*) https://www.foobar.com$1
and it is working perfectly. Now we would like to add an exception for /somepath that should not be redirected. How can I do that?
With mod_rewrite I would add a rewriterule saying "don't rewrite and stop matching", but there isn't such mechanism with redirect. Also, if I trivially reverse the regexp like !(/somepath|/someotherpath) it would no longer get the $1 parameter.