我开发了一个asp.net MVC项目。我创建了一个名为firstone
的文件夹,并将所有项目文件拖到该文件夹中。它现在工作正常。我不确定他们自己是否对自己进行了任何改变,但它在(www.forexample.com/firstone)中运行良好......
但似乎主持人不接受任何其他MVC项目。我已经存档并从该项目中下载了一切正常工作并通过URL(www.forexample.com/nextone)再次上传到另一个名为nextone的新文件夹,但令人惊讶的是它有错误。如何在一个文件夹中正常工作,并且完全相同的一个在同一主机中的另一个新文件夹中不起作用。
这是我的webconfig
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<configSections>
<sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" >
<section name="ML_VoiceRecorderFree1.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
</sectionGroup>
</configSections>
<appSettings>
<add key="webpages:Version" value="3.0.0.0"/>
<add key="webpages:Enabled" value="false"/>
<add key="ClientValidationEnabled" value="true"/>
<add key="UnobtrusiveJavaScriptEnabled" value="true"/>
</appSettings>
<system.web>
<trust level="Full"/>
<customErrors mode="Off"/>
<compilation debug="true" targetFramework="4.5"/>
<httpRuntime targetFramework="4.5"/>
</system.web>
<system.webServer>
<staticContent>
<clientCache cacheControlMaxAge ="8.00:00:00" cacheControlMode="UseMaxAge" />
</staticContent>
</system.webServer>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" culture="neutral" publicKeyToken="--------"/>
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Optimization" publicKeyToken="--------"/>
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35"/>
<bindingRedirect oldVersion="1.0.0.0-1.5.2.14234" newVersion="1.5.2.14234"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="--------"/>
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.WebPages" publicKeyToken="------"/>
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0"/>
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="--------"/>
<bindingRedirect oldVersion="1.0.0.0-5.2.2.0" newVersion="5.2.2.0"/>
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>
答案 0 :(得分:1)
您将转到IIS管理,您将创建一个名为(nextone)的文件夹并勾选设置应用程序根和匿名访问 您需要在IIS管理中创建相同的文件夹名称