首页 文章

单击Azure平台上的内部链接站点时出现404错误

提问于
浏览
0

试图处理Microsoft Azure . 放置一些应用程序,单击内部链接时每个都会出现404错误 . 在窗口中说"The resource you are looking for has been removed, had its name changed, or is temporarily unavailable" . 这是其中之一aska.azurewebsites.net

在本地计算机和另一个托管一切正常 . 假设问题出在Azure设置中 . 我怎样才能解决这个问题?

1 回答

  • 0

    找到错误的原因 . 我的项目托管在一个apache服务器上,我使用配置文件.htaccess,但Azure网站服务器 - IIS,以及配置文件web.config . 例如,我使用Yii框架编写的项目,其web.config是以下内容

    <?xml version="1.0" encoding="UTF-8"?>
    
    <rewrite>
        <rules>
        <rule name="Hide Yii Index" stopProcessing="true">
            <match url="." ignoreCase="false" />
            <conditions>
            <add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" />
            <add input="{REQUEST_FILENAME}" matchType="IsDirectory" ignoreCase="false" negate="true" />
            </conditions>
                <action type="Rewrite" url="index.php" appendQueryString="true" />
        </rule> 
        </rules>
    </rewrite>
    

    我希望这会对某人有所帮助

相关问题