Redirect domain site root to another page with URLRewrite (IIS7)


There are two ways I know to do this:

1.Method1:

<rule name=”Redirect1_For_http://mysite.com/” stopProcessing=”true”>

<match url=”^\d*$” negate=”false” />

<action type=”Redirect” url=”redirect.aspx” />

</rule>

 

2. Method 2:

<rule name=”RedirectRootToAnotherPage” enabled=”true” stopProcessing=”true”>

<match url=”^$” />

<action type=”Redirect” url=”http://mysite.com/redirect.aspx&#8221; logRewrittenUrl=”true” />

</rule>

Advertisements


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s