Quantcast
Channel: All Forums
Viewing all articles
Browse latest Browse all 28504

Redirect all subfolders to root

$
0
0

Hi,

For a specific site, I do not want any data behind my domain name. So everything needs to be redirected to the root.

I tried setting the URL Rewrite to the following:

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <rewrite>
            <rules>
                <rule name="No trailing data" patternSyntax="Wildcard" stopProcessing="true">
                    <match url="*/*" />
                    <action type="Redirect" url="/" redirectType="Permanent" />
                </rule>
            </rules>
        </rewrite>
    </system.webServer>
</configuration>
 

following items do work

my.domain.com
my.domain.com/
my.domain.com/something/
my.domain.com/something/something
...

 Only this does not work:

my.domain.com/something (without trailing slash)

Am I missing something in the pattern?


Viewing all articles
Browse latest Browse all 28504

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>