I have a website that requires reverse proxing to an alternate location but I need to keep the URL of the main site. I have an incoming rule that rewrite to the new URL and this works 100%. I then wrote a rule to rewrite the original URL so nothing appears
to change for a user. After disabling compression and using and A attribute this is rewriting the url into the address bar correctly, when any buttons are clicked on the webpage the url changes correctly, but for some reason the page content is not changing.
For example my original url is www.mysite.com I proxy this to www.mysite.org.uk and the rewrite rule makes the url appear to be www.mysite.com. It works for the homepage, but when I visit say www.mysite.com/aboutus this appears on the address bar correctly
but the page does not update to the aboutus page. Any pointers would be much appreciated.
steptoescrap...
2 Posts
URL Rewrite page not changing
Mar 14, 2012 03:28 PM|LINK
URL Rewrite reverse proxy
Dalong Zhang...
647 Posts
Microsoft
Re: URL Rewrite page not changing
Mar 16, 2012 06:16 AM|LINK
Hi,
You can create a rewrite rule capturing all the requests and rewrite to the new corresponding page. It will look like:
<rule name="page rewrite" stopProcessing="true">
<match url=".*" />
<action type="Rewrite" url="http://www.mysite.org.uk/{R:0}" />
<conditions>
<add input="{HTTP_HOST}" pattern="www\.mysite\.com" />
</conditions>
</rule>
Creating Rewrite Rules for the URL Rewrite Module
http://learn.iis.net/page.aspx/461/creating-rewrite-rules-for-the-url-rewrite-module/
Feedback to us
Develop and promote your apps in Windows Store