【问题标题】:IIS 7.5 Detailed Error - 404.0 - Not FoundIIS 7.5 详细错误 - 404.0 - 未找到
【发布时间】:2014-03-30 14:54:03
【问题描述】:

我刚刚将我的项目框架从 2.0 更改为 4.0,打开 URL 重写页面时出现错误。我有很多东西,但没有一个工作。

请帮助我解决这个问题。

错误:

HTTP Error 404.0 - Not Found
The resource you are looking for has been removed, had its name changed, or is temporarily unavailable.


Web.config:

<system.webServer>
    <staticContent>
      <clientCache cacheControlMode="UseMaxAge" cacheControlMaxAge="8.00:00:00" />
    </staticContent>
    <modules runAllManagedModulesForAllRequests="true">
      <remove name="Session" />
      <add name="Session" type="System.Web.SessionState.SessionStateModule" preCondition="" />
    </modules>
    <validation validateIntegratedModeConfiguration="false" />
    <handlers>
      <remove name="UrlRoutingHandler" />
    </handlers>
    <rewrite>
      <rules>
        <remove name="Plesk. SEO-safe redirect for http://www.theprojectjugaad.com" />
        <rule name="Plesk. SEO-safe redirect for http://www.theprojectjugaad.com" enabled="false" patternSyntax="Wildcard" stopProcessing="true">
          <match url="*" />
          <conditions>
            <add input="{HTTP_HOST}" pattern="www.theprojectjugaad.com" />
            <add input="{HTTPS}" pattern="OFF" />
          </conditions>
          <serverVariables />
          <action type="Redirect" url="http://theprojectjugaad.com/{R:1}" />
        </rule>
      </rules>
    </rewrite>
  </system.webServer>

【问题讨论】:

  • 您访问的是什么 URL(确切地说),以及您希望对其进行哪些重写以使应用程序正常工作?
  • 我使用 Global.asax 进行 URL 重写。我正在尝试访问:theprojectjugaad.com/Login/Login.html,如果我使用的是 .aspx,那么它工作正常。
  • 我不知道你的文件结构是什么样的,但你的重写规则设置了enabled="false",所以如果它以前有效,那么重写可能不是问题。
  • 是的,工作正常。
  • IIS 错误页面显示它显然正在D:\Inetpub\vhosts\jeetenparmar.net\theprojectjugaad.com\Login\Login.html 中查找 Login.html,但没有找到它。该文件实际在哪里?

标签: asp.net iis url-rewriting


【解决方案1】:

这个问题解决了吗?

我遇到了类似的错误,通过从 system.webServer 中删除 WebDAV 得到了解决

<modules runAllManagedModulesForAllRequests="true">
  <remove name="WebDAVModule" />
</modules>

【讨论】:

    猜你喜欢
    • 2018-06-23
    • 1970-01-01
    • 1970-01-01
    • 2011-08-29
    • 1970-01-01
    • 2016-07-10
    • 2015-02-02
    • 2017-07-28
    • 1970-01-01
    相关资源
    最近更新 更多