我正在嘗試製作一個很好的框架,用於插入我正在處理的網頁中的徽標。由於某些原因,IE不會顯示那個具有褪色顏色的div。我想要的只是一個帶預定義維度的空白div中的簡單漸變。谷歌鉻是顯示它就像我想要的,但IE瀏覽器不顯示任何東西。由於我已經從here複製梯度部分而不理解一個詞,我無法調試它。在div背景中的漸變樣式,在IE中不工作
下面是代碼(在一個非常簡化版本):
<!DOCTYPE html>
<html>
<head>
<meta charset="iso-8859-8-i">
<style>
#headGreen{
float: left;
margin: 52px 0px 0px 0px;
width : 300px;
height: 30px;
background-image: linear-gradient(right , rgb(255,255,255) 50%, rgb(68,179,68) 62%);
background-image: -o-linear-gradient(right , rgb(255,255,255) 50%, rgb(68,179,68) 62%);
background-image: -moz-linear-gradient(right , rgb(255,255,255) 50%, rgb(68,179,68) 62%);
background-image: -webkit-linear-gradient(right , rgb(255,255,255) 50%, rgb(68,179,68) 62%);
background-image: -ms-linear-gradient(right , rgb(255,255,255) 50%, rgb(68,179,68) 62%);
background-image: -webkit-gradient(
linear,
right top,
left top,
color-stop(0.04, rgb(255,255,255)),
color-stop(0.82, rgb(68,179,68))
);
}
#header{
width: 800px;
height: 100px;
}
</style>
</head>
<body>
<div id="header">
<div id="headGreen"></div>
</div>
</body>
</html>
我使用IE9,但我想它在其他國家也工作。 謝謝:)
http://stackoverflow.com/questions/3934693/gradients-in-internet-explorer-9的重複?換句話說,你不能。需要使用MSIE過濾器。 – anothershrubery 2012-03-13 14:36:22