Forum Discussion
Maskman_58643
Jan 14, 2010Nimbostratus
Redirect an uri without "/"
Hi,
How can create a rule that redirect an uri without anything after "/" ?
for example :
redirect a https like "https://software.tuto.com/toto" to "https...
Cspillane_18296
Jan 14, 2010Nimbostratus
Hello Maskman,
yes you can use 'starts with' and 'ends with' etc - exactly how you implement the rule is up to you.
so, for example:
=================
when HTTP_REQUEST {
switch [HTTP::uri] {
/toto { HTTP::redirect / }
}
}
=================
We're only modifying the uri here, so "/toto" becomes "/".
The host (i.e. "https://software.tuto.com") is not affected by the iRule.
So using the iRule above, a user accessing "https://software.tuto.com/toto" is redirected to "https://software.tuto.com/".
If i have understood your requirements correctly, this is exactly what you need!
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