Forum Discussion
dlogsdonmd
Nimbostratus
Dec 22, 2014301 Permanent HTTPS redirect
Hello,
I just updated an iRule for my HTTPS object as shown below, it now forwards https://cardiosmart.org to https://www.cardiosmart.org. What I need now is to modify further to incorporate a ...
dlogsdonmd
Nimbostratus
Dec 22, 2014So, you suggest to write the rule as follows? To replace the "redirect" with "respond 301 Location" (without the quotes). Is that correct?
Thank you.
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] contains "healthandwellness.cardiosmart.org" } {
HTTP::redirect "https://www.cardiosmart.org[HTTP::uri]"
}
if { [string tolower [HTTP::host]] equals "cardiosmart.org" } {
HTTP::respond 301 Location "https://www.cardiosmart.org[HTTP::uri]"
}
}
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
