Forum Discussion
I-rule for URI- redirection
We are planing for URI redirection on STG environment where we want if some one type https://abc.com/SitePages/Homepage.aspx it should redirect to https://abc.com/personal-finance/overview
Which Redirection I-rule will work for this requirement.
14 Replies
- nitass_89166
Noctilucent
if some one type https://abc.com/SitePages/Homepage.aspx it should redirect to https://abc.com/personal-finance/overview
you can check uri using HTTP::uri and redirect using HTTP::redirect command.
HTTP::uri
https://devcentral.f5.com/wiki/iRules.HTTP__uri.ashxHTTP::redirect
https://devcentral.f5.com/wiki/iRules.HTTP__redirect.ashx- krish_net_18726
Nimbostratus
Thanks for your reply, But how come pool will serve the request when both pages are served by same server. - nitass_89166
Noctilucent
sorry, what do you mean? - krish_net_18726
Nimbostratus
In this request my both URL are pointing to the same server than how the cgi_Pool will come in picture when HTTP_REQUEST { 2 if { [HTTP::uri] ends_with "cgi" } { 3 pool cgi_pool 4 } elseif { [HTTP::uri] starts_with "/abc" } { 5 pool abc_servers 6 } 7 }
- nitass
Employee
if some one type https://abc.com/SitePages/Homepage.aspx it should redirect to https://abc.com/personal-finance/overview
you can check uri using HTTP::uri and redirect using HTTP::redirect command.
HTTP::uri
https://devcentral.f5.com/wiki/iRules.HTTP__uri.ashxHTTP::redirect
https://devcentral.f5.com/wiki/iRules.HTTP__redirect.ashx- krish_net_18726
Nimbostratus
Thanks for your reply, But how come pool will serve the request when both pages are served by same server. - nitass
Employee
sorry, what do you mean? - krish_net_18726
Nimbostratus
In this request my both URL are pointing to the same server than how the cgi_Pool will come in picture when HTTP_REQUEST { 2 if { [HTTP::uri] ends_with "cgi" } { 3 pool cgi_pool 4 } elseif { [HTTP::uri] starts_with "/abc" } { 5 pool abc_servers 6 } 7 }
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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