<html>
<head><style>
/*从左往右渐变,gradientType=1*/
.body2{
FILTER: progid:DXImageTransform.Microsoft.Gradient(gradientType=1,startColorStr=#46B5FF,endColorStr=#ffffff);
}
/*从左上至右下渐变*/
body3{
FILTER: Alpha( style=1,opacity=25,finishOpacity=100,
startX=50,finishX= 100,startY=50,finishY=100);
background-color: skyblue;
}
/*从上往下渐变,gradientType=0
* 多行注释符号
*/
body4{
FILTER: progid:DXImageTransform.Microsoft.Gradient(gradientType=0,startColorStr=#ffffff,endColorStr=#000000);
}
</style></head>
<body style="filter:progid:DXImageTransform.microsoft.gradient(gradienttype=0,startColorStr=skyblue,endColorStr=white)">
<h1>网页背景渐变色</h1>
<h2>从上往下渐变,关键是设置gradientType参数值!</h2>
</body>
</html>