Hi Brandon,
Here is one option which combines the host and path for the string to check in the switch statement:
when HTTP_REQUEST {
switch -glob "[string tolower [HTTP::host]][HTTP::path]" {
"*sample.com/folder1*" {HTTP::redirect "http://site.sample.com/default.aspx"}
"*test.com/*" {HTTP::redirect "https://site.test.com/Pages/home.aspx"}
default {HTTP::redirect "https://www.test.com"}
}
}
Note, that I've tried to make the *test* case more specific to reduce the chance that the string "test" will be found in just the path. If that doesn't work for you, can you provide more examples of what you do/don't want to match for each case?
Aaron