只需要在网站设置中,“配置文件”配置一下就行了
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="HTTP to HTTPS redirect" stopProcessing="true">
<match url="(.*)" ></match>
<conditions>
<add input="{HTTPS}" pattern="^OFF$" ></add>
</conditions>
<action type="Redirect" url="https://{HTTP_HOST}/{R:1}" redirectType="Permanent" ></action>
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
本文地址:https://www.moyublog.com/notes/704.html
加入我们:微信:搜索“Moyu-Blog” 帝国CMS模板客户群:QQ二群---909235407 QQ一群(已满)---106997031
版权声明:本文采用[BY-NC-SA]协议进行授权,如无特别说明,转载请注明本文地址!