2016-08-03 43 views
0

我使用引導程序。我的CSS在這裏。它僅在此圖像內顯示白色背景。這段代碼有什麼問題?顯示白色背景而不是圖像

Image i am using here is

.container-header 
    { 
     max-width:1000px; 
     background:url(../images/header-secondrow-new.png); 
     background-repeat: repeat-y; 
     background-size: 100%; 
    } 
+1

我很抱歉,但我不明白你期待什麼?難道你希望你的圖像在水平和vertycally重複?你的'container-header'中是否有任何內容,或者只有圖像?你想要這個容器有多高? – Pipo

+0

感謝您的回覆....我修好了.. –

回答

0

試試這個:

background-image: url(../images/header-secondrow-new.png); 
background-repeat: repeat; 
background-position: center top; 
0

有一個在你的CSS代碼沒有高度值是你硝基甲苯給予高度值與不加入,你不能看到任何元素的任何內容。嘗試將height:100px添加到CSS類。