gpt4 book ai didi

css - 为 Internet Explorer 6/7/8 创建径向渐变

转载 作者:技术小花猫 更新时间:2023-10-29 10:24:14 25 4
gpt4 key购买 nike

为了在 Internet Explorer 中创建线性渐变,我曾经采用这个(糟糕的)代码:

过滤器:progid:DXImageTransform.Microsoft.gradient(startColorStr='#282828', EndColorStr='#185976');

我想知道是否存在使用滤镜和 DXImageTransoform 创建径向渐变的方法?

最佳答案

Live Demo

#element{
background: #fff; /* The color you want for the radial gradient */
width:100px;
height:100px;
filter:progid:DXImageTransform.Microsoft.Alpha(opacity=100, finishopacity=0, style=2);
}

Link where I got the info

径向渐变

For the Radial Gradient we have to create a div-elements. This element is a Overlay for the background. Than we'll use the Alpha-Filter. Alpha will make this element transparent in a special style. style=2 is a radial alpha. This means that the center of the element will be full colored (opacity=100) and the opacity will lose to the edges (finishopacity=0)

关于css - 为 Internet Explorer 6/7/8 创建径向渐变,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7230250/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com