|
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="redirector" type="SampleRedirector.Configuration.RedirectorConfiguration, SampleRedirector" />
</configSections>
<!-- RedirectorConfiguration in the same config file, to avoid test project path problems-->
<redirector ignoreRegex=".*(\.css|\.txt|\.js|\.gif|\.jpg|\.png)">
<urlGroups>
<add regex="/news-items/.+">
<!-- Items redirection that are inside a folder-->
<urls>
<add regex="/news-items/index.html" replacement="/news-items/" />
<add regex="/news-items/article(\d+).html" replacement="/news-items/interesting-article$1.aspx" />
</urls>
</add>
<add regex="/press-releases.*">
<!-- Folder redirection (change name). From /press-releases/ to /press/ -->
<urls>
<add regex="/press-releases(.*)" replacement="/press$1" />
</urls>
</add>
<add regex="^http://www.contoso.com.*">
<!-- Domain or subdomain redirection -->
<urls>
<add regex="^http://www.contoso.com(.*)$" replacement="http://contoso.com$1" />
</urls>
</add>
</urlGroups>
</redirector>
</configuration>
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.