IIS(Internet Information Services)是微软公司提供的Web服务器软件,用于托管Web应用程序。ThinkPHP是一个流行的PHP框架,用于快速开发Web应用程序。
public
目录,并在该目录下创建一个web.config
文件。web.config
文件,添加以下内容:<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="ThinkPHP" stopProcessing="true">
<match url=".*" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Rewrite" url="/index.php" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
web.config
文件位于public
目录下,并且内容正确。领取专属 10元无门槛券
手把手带您无忧上云