Last active
July 19, 2017 17:02
-
-
Save rbaty-barr/f713c6fb0f0510c2333d63334ece31bd to your computer and use it in GitHub Desktop.
Rewrite rules example for web.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<rewrite> | |
<rules> | |
<rule name="orgRewrite" stopProcessing="true"> | |
<match url="(.*)" ignoreCase="true" /> | |
<conditions logicalGrouping="MatchAll"> | |
<add input="{HTTP_HOST}" pattern="^www\.(.+)$" /> | |
</conditions> | |
<action type="Redirect" url="http://{C:1}/{R:0}" appendQueryString="true" redirectType="Permanent" /> | |
</rule> | |
<rule name="Redirects umbraco.io to actual domain" stopProcessing="true"> | |
<match url=".*" /> | |
<conditions> | |
<add input="{HTTP_HOST}" pattern="^(.*)?.s1.umbraco.io$" /> | |
<add input="{REQUEST_URI}" negate="true" pattern="^/umbraco" /> | |
<add input="{REQUEST_URI}" negate="true" pattern="localhost" /> | |
</conditions> | |
<action type="Redirect" url="http://ilpf-supportyourfund.org/{R:0}" appendQueryString="true" redirectType="Permanent" /> | |
</rule> | |
</rules> | |
</rewrite> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment