Forum Discussion
Stealth Redirection or URL Hiding
The problem basically boils down to DNS and HTTP protocol characteristics. When you issue a redirect to a browser, you're sending it a 30x status message with a Location header with a URL. That combination causes the browser to resolve this address and then navigate directly to it. This will also cause the browser's address bar to change. The www.abc.com and news.xxx.com servers live in different places and resolve to different IP addresses, so if you need the browser address bar to stay the same, you have to force all of the traffic through your proxy.
Addressing your iRule, the first part will send the browser off to news.xxx.com if the request is for www.abc.com/news. The second part, the elseif clause, will never happen because a browser request for news.xxx.com will never go through your proxy.
This leaves you with about two options:
-
Force the news.xxx.com traffic through your proxy by maintaining the www.abc.com URL and sending to a pool or node.
-
Less of a proxy solution, you could maintain the www.abc.com URL and use Ajax to asynchronously collect the news.xxx.com content and render locally. This would obviously require a lot more dev work on your part, so option 1 is going to be much easier.
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