2011-11-06 108 views
0

我不明白爲什麼這個背景圖片不顯示。看起來圖像正在發送到瀏覽器,並且css規則正在被應用。css背景圖片不顯示

當我檢查元素時,我得到了這些匹配的規則。當我點擊'images/o.png'鏈接時,它顯示了我的預期圖像 .player1_move { width:30px; height:30px; background-image:url('images/o.png'); }

-----------下面是CSS和HTML我有---------

.player1_move { 
    width: 30px; 
    height: 30px; 
    background-image: url('images/o.png'); 
    } 

<table> 
    <tr> 
    <td id = "0-0" class="player1_move"></td> 
    </tr> 
</table> 

回答

1

我的猜測是,你的細胞是空的這就是爲什麼它沒有顯示。

在你的CSS補充一點:

table{ 
    empty-cells: show; 
}