2012-11-28 54 views
0

我在Chromium中遇到了一個煩人的問題。在Chrome上的小<input type ='button'>上的CSS sprite

這裏是代碼:

<input type="button" class="expand_bt" value=" "> 


.expand_bt { 
    background: url('../img/actions_btns.jpg') -2340px -542px no-repeat; 
    height: 24px; 
    width: 26px; 
    border: none; 
    cursor: pointer; 
} 

它顯示沒有在鉻,所有罰款的Firefox。但是這個:

<input class="btn_save" value=" " id="save_general" type="button"> 

.btn_save { 
    background: url('../img/actions_btns.jpg') -178px -550px no-repeat; 
    height: 38px; 
    width: 122px; 
    border: none; 
    cursor: pointer; 
} 

在兩者中都完全正常工作。邏輯在哪裏?我錯過了什麼? 感謝您的關注。

+0

你爲什麼要移動背景圖像這麼多? – gaynorvader

+1

其工作很好的傢伙。 –

+0

1)因爲我使用CSS sprite 2)它不適用於我o_O –

回答

0

緩存問題。我必須直接進入圖像位置並按Ctrl + Shift + r。不知道爲什麼Chromium沒有從包含頁面的緩存本身刷新圖像。

相關問題