CSS makes an element translucent
Mar 20, 2017 am 10:45 AMThis article mainly introduces the relevant information on using CSS to set an element to be translucent. It is very good and has reference value. Friends who need it can refer to it
.opacity{ filter:alpha(opacity=50); /* IE */ -moz-opacity:0.5; /* 老版Mozilla */ -khtml-opacity:0.5; /* 老版Safari */ opacity: 0.5; /* 支持opacity的浏览器*/}
Use it Set an element to be semi-transparent
.filter = "alpha(opacity=" + opacity + ")"; /* IE */ .MozOpacity = (opacity / 100); /* 老版Mozilla */ .KhtmlOpacity = (opacity / 100); /* 老版Safari */ .opacity = (opacity / 100); /* 支持opacity的浏览器*/
When scaling images on the Windows platform, image distortion may occur. You can use IE’s proprietary command:
img{-ms-interpolation-mode: bicubic;}
The above is introduced by the editor. Use CSS to set an element to be translucent. I hope it will be helpful to everyone. If you have any questions, please leave me a message and the editor will reply to you in time. I would also like to thank you all for your support of the PHP Chinese website!
For more articles related to CSS setting an element to be translucent, please pay attention to the PHP Chinese website!
Related articles:
CSS3 Tutorial (8): CSS3 Transparency Guide
Example instructions for using RGBa to adjust transparency in CSS3

Hot Article

Hot tools Tags

Hot Article

Hot Article Tags

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

What language is the browser plug-in written in?
