宝塔如何配置跳转到https
因为宝塔默认了webconfig 文件。修改后容易500错误
宝塔后台,网站-设置-伪静态
![宝塔如何配置跳转到https插图 宝塔如何配置跳转到https插图](https://www.laoyang.work/wp-content/uploads/2022/05/808.jpg)
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name=”http redirect to https” stopProcessing=”true”>
<match url=”(.*)” />
<conditions>
<add input=”{HTTPS}” pattern=”^OFF$” />
<add input=”{HTTPS_HOST}” pattern=”^(localhost)” negate=”true” />
</conditions>
<action type=”Redirect” url=”https://{HTTP_HOST}/{R:1}” />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>