Wednesday, December 22, 2021

Problem with rewrite in httpd

This works for both https://example.com/foo and https://example.com/foo/

location match "^/foo/?$" {
request rewrite "/about.php"
}

This doesn't work at all:

location match "^/foo-bar/?$" {
request rewrite "/about.php"
}

Seems like the "-" sign makes it break. What am I missing?

No comments:

Post a Comment