Forum Discussion
DPIT_323803
Nimbostratus
Oct 05, 2017domain redirect
a lot domains should be redirected to one single domain
jaikumar_f5
Noctilucent
Oct 07, 2017Which version you're running on. If running on 11.5.x or above, use the rewrite profile:
- clientside : https://www.blah-test.com/
- serverside : https://www.mainpage.de/
else,
when HTTP_REQUEST {
if { ([HTTP::host] equals "www.blah-test.com") } {
HTTP::host [string map {www.blah-test.com www.mainpage.de} [HTTP:host]]
}
}
when HTTP_RESPONSE {
if { [HTTP::header values Location] contains "www.mainpage.de" } {
HTTP::header replace Location [string map {www.mainpage.de www.blah-test.com} [HTTP::header value Location]]
}
}
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects