ASP.NET MVC 加载不到css样式
运行效果如下:
F12开发者工具查看到.css文件里什么都没有:
StyleControl.css:
body {
padding-top: 50px;
padding-bottom: 20px;
}
/* Set padding to keep content from hitting the edges */
.body-content {
margin-top:20px;
padding-left: 15px;
padding-right: 15px;
}
/* Override the default bootstrap behavior where horizontal description lists
will truncate terms that are too long to fit in the left column
*/
.dl-horizontal dt {
white-space: normal;
}
.input-group {
max-width:280px;
}
/* Set width on the form input elements since they're 100% wide by default */
input,
select,
textarea {
max-width: 280px;
}
.loginform{
max-width:320px;
margin:auto;
}
.loginform .form-control
{
max-width:none;
}
BundleConfig.cs:
很坑爹啊。。为什么css加载不出来??
坑爹的解决方案:
将StyleControl.css改成stylecontrol.css,BundleConfig.cs也改成用小写的:
运行效果:
居然可以了!!!
好坑啊。。只支持小写吗,心累,懂的朋友解释一下,谢谢!