Forum Discussion
Korai
Nimbostratus
Mar 01, 2021Redirect Two URLs to Single URL
Hi, I have a requirement to redirect traffic for two URLs to a single URL by using irule. Suppose traffic for https://abc.com/path1 and for https://xyz.com/path2 should be redirected to h...
Mayur_Sutare
MVP
Mar 04, 2021Hi, use below iRule.
when HTTP_REQUEST {
if {(([HTTP::host] eq "abc.com") && (([string tolower [HTTP::uri]] starts_with "/path1") || ([string tolower [HTTP::uri]] starts_with "/path2"))) }
{
HTTP::redirect https://newsite.com/path3/abc
}
}- KoraiMar 04, 2021
Nimbostratus
Thanks It works
Both URLs are directed to single URL and successfully tested
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
