2

我只是想修改 MVC 4 互联网应用程序项目主页上“特色”(浅蓝色)部分的背景颜色。这在 Firefox 中运行良好。我看不到 Chrome 的变化,它总是原来的浅蓝色。为什么?

.featured .content-wrapper {
    background-color: #ffffff;
4

1 回答 1

1

在 MVC4 应用程序的默认 Site.css 中,您将拥有这些行

background-image: -webkit-gradient(linear, left top, right top, color-stop(0, #7ac0da), color-stop(1, #a4d4e6));
background-image: -webkit-linear-gradient(left, #7ac0da 0%, #a4d4e6 100%);

之内

.featured .content-wrapper { }

Chrome 将以比background-color: #ffffff;规则更高的优先级使用它们,这就是为什么特色文本仍然具有蓝色背景的原因。

于 2013-04-03T13:17:04.510 回答