在每个资源的结果:无法加载与服务code 500资源 [英] Every resource results in: Failed to load resources with service code 500

查看:98
本文介绍了在每个资源的结果:无法加载与服务code 500资源的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个新的Windows 10机器试图通过Visual Studio但页面只是部分负荷运行MVC应用程序。当铬的F12开发者控制台找我看到所有调用布局页面的CSS和脚本文件都造成了无法加载的服务code 500的资源

I have a new windows 10 machine trying to run an mvc application through visual studio but the page only partially loads. When looking at the F12 developer console in chrome I see that all the css and script files called in the layout page are all resulting in a "Failed to load resources with service code 500"

此应用程序运行在多台其他机器完全正常,只是没有上新的。状态code 500使我相信一定有某种与IIS前preSS Visual Studio的问题在运行在Visual Studio本身的应用,或者一些其他配置。

This application runs perfectly fine on multiple other machines, just not on the new one. The status code 500 leads me to believe there must be some sort of problem with the iis express visual studio runs the application in, or some other configuration with in visual studio itself.

推荐答案

OK设法遇到另一个话题确切的问题:

OK managed to come across another topic with the exact problem:

无法加载的所有资源 - 错误500

在我的情况下,我通过日志文件检查,发现有对.LESS文件中定义的一个重复的MIME类型。

In my case I checked through the log files and found there was a duplicate MIME type defined for .less files.

这已经在我的web.config文件中被定义为,这是不是在所有的其他机器的IIS防爆preSS对ApplicationHost.config自动定义,但我的新机,这已被自动定义等有一个重复的条目。我已经从IIS配置中删除这一点,现在工作得很好。

This has been defined in my web.config file as this wasn't automatically defined in the IIS Express applicationhost.config on all the other machines, but for my new machine, this has been automatically defined and so there was a duplicate entry. I have removed this from the iis config and works fine now.

这篇关于在每个资源的结果:无法加载与服务code 500资源的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆