I had hosted the sites using the iis 10 with application on the site like below structure:
Mysite staging Physical Path is D:\inetpub\MysiteStaging mysitestaging application physical path is D:\inetpub\MysiteStaging\staging
https://www.mysitestaging.com/mysitestaging/Login/Login.aspx is working fine. I need to redirect to this url https://www.mysitestaging.com/mysitestaging/Login/Login.aspx when users type https://www.mysitestaging.com or any text in between the domain name https://www.mysitestaging.com and /Login/Login.aspx like this https://www.mysitestaging.com/anytext/Login/Login.aspx. Currently I am getting the 404 resource cannot be found.
Any help is really appreciated.
Thanks
Sabbu
CodePudding user response:
You can try this rule:
<rule name="test" stopProcessing="true">
<match url="^(^$|(.*)/Login/Login.aspx)$" />
<action type="Redirect" url="/mysitestaging/Login/Login.aspx" />
</rule>