0
您好,我有一個問題,我的MVC 2 ASP.NET在IIS 7.5IIS無法找到應用程序!
Server Error in Application "ORDERS"Internet Information Services 7.5
Error Summary
HTTP Error 404.0 - Not Found
The resource you are looking for has been removed, had its name changed, or is temporarily unavailable. Detailed Error Information
Module IIS Web Core
Notification MapRequestHandler
Handler StaticFile
Error Code 0x80070002
Requested URL http://localhost:8080/home
Physical Path C:\Ordering\home
Logon Method Anonymous
Logon User Anonymous
運行我本地出版它,然後將文件複製到服務器,並將它們丟棄到c:\訂購。當我嘗試運行localhost:8080/home時,無法找到它!
編輯:
我後來發現,這是一個重定向的問題 - 這是心不是踢在重定向到/ home或/帳號/ LogOn支持
繼承人的web.config文件,如果有幫助:
<?xml version="1.0"?>
<configuration>
<connectionStrings>
<add name="ApplicationServices" connectionString="data source=.\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|ASPNETDB.MDF;User Instance=true"
providerName="System.Data.SqlClient" />
<add name="orderbaseConnectionString" connectionString="Data Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\orderbase.mdf;Integrated Security=True;User Instance=True"
providerName="System.Data.SqlClient" />
</connectionStrings>
<system.web>
<compilation debug="true" targetFramework="4.0">
<assemblies>
<add assembly="System.Web.Abstractions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Web.Routing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
<add assembly="System.Web.Mvc, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
</assemblies>
</compilation>
<customErrors mode="Off"/>
<authentication mode="Forms">
<forms loginUrl="~/Account/LogOn" timeout="2880" />
</authentication>
<membership>
<providers>
<clear/>
<add name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider" connectionStringName="ApplicationServices"
enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" requiresUniqueEmail="false"
maxInvalidPasswordAttempts="5" minRequiredPasswordLength="6" minRequiredNonalphanumericCharacters="0" passwordAttemptWindow="10"
applicationName="/" />
</providers>
</membership>
<profile>
<providers>
<clear/>
<add name="AspNetSqlProfileProvider" type="System.Web.Profile.SqlProfileProvider" connectionStringName="ApplicationServices" applicationName="/" />
</providers>
</profile>
<roleManager enabled="true">
<providers>
<clear />
<add connectionStringName="ApplicationServices" applicationName="/"
name="AspNetSqlRoleProvider" type="System.Web.Security.SqlRoleProvider" />
<add applicationName="/" name="AspNetWindowsTokenRoleProvider"
type="System.Web.Security.WindowsTokenRoleProvider" />
</providers>
</roleManager>
<pages>
<namespaces>
<add namespace="System.Web.Mvc" />
<add namespace="System.Web.Mvc.Ajax" />
<add namespace="System.Web.Mvc.Html" />
<add namespace="System.Web.Routing" />
</namespaces>
</pages>
</system.web>
<system.webServer>
<validation validateIntegratedModeConfiguration="false"/>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0" newVersion="2.0.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>
任何幫助表示讚賞!
好的,謝謝,但是當我在本地IIS上運行時,轉發到/ home或/ account/logon是自動完成的 - 我沒有添加任何虛擬目錄。 – bergin 2010-07-10 10:54:20
你應該在國際空間站的某個地方定義,它應該等待8080端口的請求,如果請求來到http:// localhost:8080/home,它應該搜索像defaul.html,default.asp,default.aspx等等文件(參見標準文檔配置)。這可能是你錯誤的很多原因。它必須在ISS配置中,您不要在這裏發佈。 – Oleg 2010-07-10 11:27:09
當前查看: http://stackoverflow.com/questions/384184/asp-net-mvc-page-can-not-found 不知道如何將映射添加到: C:\ WINDOWS \ Microsoft.NET \ Framework \ v2.0.50727 \ aspnet_isapi.dll – bergin 2010-07-10 11:47:14