ASP.NET/IIS7 URL not working

I followed the instructions to Examine the IIS web page to add static redirects with a rewrite map for my asp.net application.

The following is the configuration:

<rule name="Redirect rule1 for Information" stopProcessing="true">
    <match url=".*" />
    <conditions logicalGrouping="MatchAll" trackAllCaptures="false">
        <add input="{Information:{REQUEST_URI}}" pattern="(.+)" />
    </conditions>
    <action type="Rewrite" url="{C:1}" appendQueryString="true" />
</rule>

and

<rewriteMaps>
    <rewriteMap name="Information">
        <add key="/Information/CorporateSales.aspx"
             value="/KB/Information/CorporateSales" />
        <add key="/Information/ComputerRepair.aspx"
             value="/KB/Information/ComputerRepair" />
    </rewriteMap>
</rewriteMaps>

It was even originally created by a wizard in IIS Manager to use rewriting cards.

So the idea is that /Information/CorporateSales.aspx/KB/Information/CorporateSaleswith 301 redirect (MOVED CONSTANT).

However, I just get the aspx source page (which we delete later). I even deleted the file because it used the existing resource by default, and with that I just get a simple 404 without redirection.

Does anyone have an idea?

Let me clarify:

, . . .

+5
5

http://www.iis.net/learn/extensions/url-rewrite-module/using-rewrite-maps-in-url-rewrite-module .

<rewrite>
    <rules>
        <rule name="Redirect rule1 for RedirectURLs">
            <match url=".*" />
            <conditions>
                <add input="{RedirectURLs:{REQUEST_URI}}" pattern="(.+)" />
            </conditions>
            <action type="Redirect" url="{C:1}" appendQueryString="false" />
        </rule>
    </rules>
    <rewriteMaps>
        <rewriteMap name="RedirectURLs">
            <add key="/privacy.php" value="/privacy" />
        </rewriteMap>
    </rewriteMaps>
</rewrite>
+5

, . , , .

My rewriteMap URL- "/Default2.aspx" "/Dashboard.aspx".

Default2.aspx, 404, Dashboard.aspx, .

, . rewriteMap , ( ), , "/TestSite/Default2.aspx".

, rewriteMap , . , , , {REQUEST_FILENAME}, {REQUEST_URI}. {REQUEST_FILENAME} URL- rewriteMap.

+2

Url, IIS7/7.5? . , , pipline, .

Edit

:

http://learn.iis.net/page.aspx/469/using-rewrite-maps-in-url-rewrite-module/

, , , stopProcessing. ?

0

, .

<match url="(.*)" />

, ,

 <add input="{Information:{REQUEST_URI}}" pattern="(.+)" />

URL, . URL: www.example.com/Information/CorporateSales.aspx Information/CorporateSales.aspx on rewriteMap

, , URL

www.example.com/old/Information/CorporateSales.aspx

0

reset iis-?

72 (iirc).

-2

All Articles