Quantcast
Channel: ASP.NET Core
Viewing all articles
Browse latest Browse all 9386

Web Config rewrite rules

$
0
0
<system.webServer><rewrite><rules><rule name="http to https" stopProcessing="true"><match url=".*"/><conditions><add input="{HTTPS}" pattern="off"/></conditions><action type="Redirect" url="https://www.{HTTP_HOST}/{R:0}"/></rule></rules></rewrite></system.webServer>

this works fine  using    http://website.com   or website.com , it is direct to the secure site, but if the user typewww.website.com  it doesn't work, it appendswww.www.website.com.   How do I write this to cover both ways, due to SEO requirements they want everything redirected tohttps://www.website.com

Thanks


Viewing all articles
Browse latest Browse all 9386

Trending Articles



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