November Happy Hour will be moved to Thursday December 5th.

trailing slash is removed from redirect

Vote:
 
Has anyone stumbled upon this when doing a redirect and do yo usually create a site in iis for http or just handle the redirect in web config alone?

Adding this rule in web.config of an asp.net 4.5 project:

http://site1.internal.sw-company.com/page1 redirects me to .compage1 (notice slash / sign is missing between .com and page1 in the redirect)

How would you fix this?

#154822
Aug 30, 2016 16:53
Vote:
 

This works for me with all query strings:

<rule name="HTTP to HTTPS redirect" stopProcessing="true">
    <match url="(.*)" />
    <conditions>
    <add input="{HTTPS}" pattern="off" ignoreCase="true" />
    </conditions>
    <action type="Redirect" redirectType="Permanent" url="https://{HTTP_HOST}/{R:1}" />
</rule>
#154823
Aug 30, 2016 16:58
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.