CSSopacity-code for implementing the image translucent effect a few days ago, a web design friend asked me this question: how to implement the image translucent effect through CSS, and can be supported in IE and Mozilla. I will share my methods with you.
For image transparency through CSS
This effect works on both IE and Mozilla browsers. The Code is as follows:
This. filters. alpha. opacity = 100 "onmouseout =" this. style. Required opacity = 0.5;
This. filters. alpha. opacity = 50 ">
In IE, you need to use "filter" to define transparency "opacity". In Mozilla, you can directly parse "opacity ", therefore, if you want to make this effect supported in both browsers, you need to add both settings. For IE settings: this. filters. alpha. opacity = 50 but for Mozilla: this. style. required opacity = 0.5. you can use this line of code to define images. You only need to modify the image address to achieve the effect.
Image with link: