DIV background semi-transparent text non-translucent style

DIV background semi-transparent text non-translucent style
DIV background is semi-transparent, but the words in DIV are not semi-transparent

Copy code
The code is as follows:

<body bgcolor="#336699">
<div style="filter:alpha(opacity=50);background:#ffffff;width:600;"><span style="color:yellow">

The layer background is semi-transparent, and the font color is also semi-transparent

Copy code
The code is as follows:

</span></div>
<div style="filter:alpha(opacity=50);background:#ffffff;width:600"><span style="position:relative;color:yellow">The layer background is semi-transparent, and the font color is not semi-transparent</span></div>

*******The layer with filter must have width attribute, otherwise the filter will be invalid. ********

We can use CSS style filters to set filter effects on some HTML tags.

example:

Black and white photo filter: gray;
X-ray photofilter: Xray;
Wind blur filter: blur(add=true,direction=45,strength=30);
Sine wave filter: Wave(Add=0, Freq=60, LightStrength=1, Phase=0, Strength=3);
Translucent effect filter: Alpha(Opacity=50);
Linear transparent filter: Alpha(Opacity=0, FinishOpacity=100, Style=1, StartX=0, StartY=0, FinishX=100, FinishY=140);
Radiation transparency filter: Alpha(Opacity=10, FinishOpacity=100, Style=2, StartX=30, StartY=30, FinishX=200, FinishY=200);
White transparent filter: Chroma(Color=#FFFFFF);
Reduce color filter: grays;
Negative effect filter: invert;
Flip left and right filter: fliph;
Vertical flip filter: flipv;
Projection effect filter:progid:dXImageTransform.Microsoft.DropShadow(color=#cccccc,offX=5,offY=5,positives=true);
Mosaic filter:progid:dXImageTransform.Microsoft.Pixelate(maxsquare=3);
Glow effect filter:progid:dXImageTransform.Microsoft.Glow(color=#cccccc,Strength=5);
Soft edge effect filter:alpha(opacity=100, finishOpacity=0,style=2

<<:  Best Practices Guide for Storing Dates in MySQL

>>:  Vue+webrtc (Tencent Cloud) practice of implementing live broadcast function

Recommend

Analysis of examples of using anti-shake and throttling in Vue components

Be careful when listening for events that are tri...

Brief introduction and usage of Table and div

Web front end 1 Student ID Name gender age 01 Zha...

Detailed explanation of the usage of two types of temporary tables in MySQL

External temporary tables A temporary table creat...

mysql 8.0.19 win10 quick installation tutorial

This tutorial shares the installation tutorial of...

How to add a pop-up bottom action button for element-ui's Select and Cascader

As shown in the figure below, it is a common desi...

How to configure multiple tomcats with Nginx load balancing under Linux

The methods of installing nginx and multiple tomc...

Analysis of Linux configuration to achieve key-free login process

1.ssh command In Linux, you can log in to another...

How to clean up Alibaba Cloud MySQL space

Today I received a disk warning notification from...

Detailed explanation of MySQL persistent statistics

1. The significance of persistent statistical inf...

Detailed explanation of root directory settings in nginx.conf

There are always some problems when configuring n...

Usage of Linux userdel command

1. Command Introduction The userdel (user delete)...

Mysql case analysis of transaction isolation level

Table of contents 1. Theory SERIALIZABLE REPEATAB...

Analysis of the principles of docker containers

Table of contents 01 What is the essence of a con...

How to deploy SpringBoot project using Docker

The development of Docker technology provides a m...