Forum Discussion
Hostname turns into server internal name
Hi All,
Thanks for you replies. I suspect from the internal server doing this redirection but i do not know exact reason.
I will check more detail and inform you.
Hi Kevin by the way, there is a redirection irule on VIP like ;
if [HTTP::uri] equals "/" do HTTP::redirect "/blabla"
Regards,
If that does not help you then you can try the following simplified code to solve your problem. This will ensure that all redirects relative. This takes http://mylocal.server.com/anyway?hello=1 and makes it /anyway?hello=1. This means it will not longer change the name of the server in the browser.
when HTTP_REQUEST {
if {[HTTP::status] eq 302} {
if {[HTTP::header Location] starts_with "http"} {
HTTP::header replace Location "/[getfield [HTTP::header Location] {/} 4]"
}
}
}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