2013-03-05 97 views
2

当我把下面的CSS,背景图像不来ie8和ie7。背景不工作在IE8

#bottom-thumb2{  
    width: 212px; 
    height:300px; 
    /*margin:5px 5px 5px 5px;*/ 
    padding:7px; 
    width:23%; 
    border-right:2px #cecece solid; 
    background: url(../images/user912_modules_bg.png)repeat-y scroll right center rgb(255, 255, 255) ; 
    font-size: 11px; 
    float:left; 
    overflow:auto; 
} 

回答

2

你就在这条线url(../images/user912_modules_bg.png)repeat-y,而不是url(../images/user912_modules_bg.png) repeat-y缺少空间。


试试这个:

background: url(../images/user912_modules_bg.png) repeat-y scroll right center rgb(255, 255, 255) ; 

为了避免混淆,分别申报。像这样:

background-image: url(../images/user912_modules_bg.png); 
background-repeat: repeat-y; 
background-attachment: scroll; 
background-position: right center; 
background-color: rgb(255, 255, 255) ; 
+0

边框语法不正确。它可以按照您列出的任何顺序。 – Raptor 2013-03-05 04:34:30

+0

我知道。阅读链接示例。形式语法可以按任意顺序。引用:*规范顺序:在值的形式语法中出现的顺序* – Raptor 2013-03-05 04:40:02

+0

@ShivanRaptor雅我现在明白你的观点。对不起,这是一个小白菜。我正在消除这一点。 – 2013-03-05 04:45:31

0

你应该使用什么宽度? 图像的宽度是多少? 212px或23%?您目前正在定义/使用两种...