IE8 Gradient没有出现

时间:2012-01-31 10:59:08

标签: html css internet-explorer-8

我正在修复Internet Explorer 8的模板,现在我有一个问题。为什么渐变不出现在具有CSS的元素上:display: table;

有没有解决方案?

filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#5d6372', endColorstr='#8d929e',GradientType=0 );

1 个答案:

答案 0 :(得分:0)

startcolorstrendcolorstr需要8个十六进制数字;你只有6岁。

编辑:没有等待,那不可能。你的原始风格确实适用于IE8。

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
 <head>
  <title>IE8 Gradient test</title>
 </head>
 <body>
  <div style="display:table; width:100%; filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#5d6372', endColorstr='#8d929e', GradientType=0 );">
   <div style="display:table-row"><div style="display:table-cell">test</div></div>
  </div>
 </body>
</html>

那么你能展示你的尝试吗?

相关问题