Setting Up web.config for an https redirect (SSL)

The following code needs to be added to the site's web.config file to force the site to render in https after installing the SSL.

<rulename="Force WWW and SSL"enabled="true"stopProcessing="true">

<matchurl="(.*)"/>

<conditionslogicalGrouping="MatchAny">

<addinput="{HTTP_HOST}"pattern="^[^www]"/>

<addinput="{HTTPS}"pattern="off"/>

</conditions>

<actiontype="Redirect"url="https://www.partsshuttle.com/{R:1}"appendQueryString="true"redirectType="Permanent"/>

</rule>
Was this answer helpful? 0 Users Found This Useful (0 Votes)