.net 4.5 Asp Mvc->错误403.14-IIS 7-Windows Server 2008 R2 [英] .net 4.5 Asp Mvc -> Error 403.14- IIS 7 - Windows Server 2008 R2
问题描述
当我想在自己的iis上部署MVC 4(.net 4.5)应用程序时,我收到403.14的消息,称内容不可浏览。
When I want to deploy an MVC 4 (.net 4.5) application to my iis i got the 403.14 calling me that the content ist not browseable.
当我部署未更改的mvc 4模板时发生。
This also occurs when i deploy the unchanged mvc 4 template.
当在.net 4.0中使用mvc 4模板时,一切正常。
我检查了其他帖子,但找不到解决方案。
when using the mvc 4 template with .net 4.0 everything works. I checked the other posts but can't figure out the solution.
ist set
我运行了aspnet_regiss -i,它已完成,没有任何错误。
i ran aspnet_regiss -i which completed without any errors.
唯一奇怪的是,.net 4.5安装在.net 4.0目录%windows%/ microsoft.net中/ Framework64 / 4.0.30319
我还从该文件夹中运行过aspnet_regiis。
the only strange thing is that .net 4.5 is installed in the .net 4.0 directory %windows%/microsoft.net/Framework64/4.0.30319 From this folder i also ran aspnet_regiis.
为确保已安装4.5,我重新启动了。净4.5设置,它告诉我说它是已安装
to ensure that 4.5 is installed i restarted the .net 4.5 setup and it tells me taht it is installes
此外,应用池显示了我 4.0.30319 作为版本。
Also the apppools show me 4.0.30319 as version.
还有另一个针对mvc且运行4.5的应用程序。但是我不知道它是否是用4.0模板创建的,并重新定位为4.5
有什么提示吗?
There is an other application targeting mvc with 4.5 which runs. but i don't know wether it was created with a 4.0 templated and retargeted to 4.5 Any hints?
app.config是从mvc 4模板。
The app.config is the unchanged default from the mvc 4 template.
我刚刚测试过创建一个子文件夹,然后将其转换为应用程序。将网站放置在该位置使其可以在主页上正常工作。但是所有子页面(例如登录结尾ab)都以404未找到
I just tested to create a subfolder which i convert to an application. placing the site there makes it working for the main page. But all subpages forexample login end ab in a 404 Not Found
但是为什么不在根文件夹上?
But why not on root folder?
推荐答案
.net 4.5替代.net4。 http://msdn.microsoft .com / en-us / library / 5a4x27ek.aspx 。
您可能希望在web.config文件中使用它来使应用程序正常工作:
.net 4.5 replaces .net 4. http://msdn.microsoft.com/en-us/library/5a4x27ek.aspx. You probably want to use this in your web.config file to make you application work:
<system.webServer>
<modules runAllManagedModulesForAllRequests="true" />
...
</system.webServer>
如果代码符合您的要求,则可以按照此处所述的正确方式进行操作:
http://www.britishdeveloper.co.uk/2010/ 06 / dont-use-modules-runallmanagedmodulesfo.html
If the code does what you want then you will want to do it the proper way as described here: http://www.britishdeveloper.co.uk/2010/06/dont-use-modules-runallmanagedmodulesfo.html
这篇关于.net 4.5 Asp Mvc->错误403.14-IIS 7-Windows Server 2008 R2的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!