Forum Discussion
Ravi_110217
Nimbostratus
Mar 11, 2008new HTTP page redirection request
Hello GuYs,
I am wondering if someone could help me out with HTTP page redirection rule... I have tried with couple of rules but none of them worked. See example below that how do I want to ...
The_Bhattman
Nimbostratus
Mar 13, 2008Hi Ravi,
After looking at your logs it appears that the information you initially provided isn't exactly matching to what the irule was written.
Is the goal to redirect http://www.payonce.com.au/personelcredit to http://www.oncecredit.com/OnceOnline/99.aspx?
In that case you will want to write the irule to the following:
when HTTP_REQUEST {
log local0. "The host is http://[HTTP:host]"
log local0. "The uri is [HTTP::uri]"
if { ([HTTP::host] eq "www.payonce.com.au") && ([HTTP::uri] eq "/personalcredit") } {
log local0. "redirecting user... to "
HTTP::redirect "http://www.oncecredit.com/OnceOnline/99.aspx" }
}or
If you want redirect
http://anything.com/personalcredit to http://www.oncecredit.com/OnceOnline/99.aspx
when HTTP_REQUEST {
log local0. "The uri is [HTTP::uri]"
if { [HTTP::uri] eq "/personalcredit" } {
log local0. "redirecting user... to "
HTTP::redirect "http://www.oncecredit.com/OnceOnline/99.aspx" }
}or
If you want to redirect http://anything.com/personalcredit to http://anything.com/Onceonlone/99.aspx.
when HTTP_REQUEST {
log local0. "The uri is [HTTP::uri]"
if { [HTTP::uri] eq "/personalcredit" } {
log local0. "redirecting user... to "
HTTP::redirect "http://[HTTP::host]/OnceOnline/99.aspx" }
}Let's hope this helps.
Thanks CB
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