Forum Discussion
url response rewrite
Hi Fahmi,
I just wanted to clarify what your goal is: are you trying to change 'https://abc.xyz.com/index.html' to 'https://abc.xyz.com:81/directory/' after the user requests a certain URL?
Or are you simply trying to redirect if they request index.html?
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] eq "abc.xyz.com" and [HTTP::path] eq "/index.html" } {
HTTP::respond 301 Location "https://abc.xyz.com:81/directory/"
}
}
Best,
Andrew
- FahmiJun 18, 2019Nimbostratus
Hi Andrew,
my goal is to redirect the response from the server to client because when the user access "https://abc.xyz.com/index.html" they getting it's right but when they click a menu it's suppose to get a response from the server like this https://abc.xyz.com/directory/ but instead they getting a response http://abc.xyz.com:81/directory/,
note: the local server is running on port 81
thank you.
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