CodeLab
Show Output
 
xxxxxxxxxx
19
 
1
<!DOCTYPE html>
2
<html lang="en">
3
<head>
4
<meta charset="utf-8">
5
<title>Example of Defining Fallback Color for RGBA</title>
6
<style> 
7
    p {
8
        padding: 20px;
9
        /* Fallback for web browsers that doesn't support RGBA */
10
        background:rgb(0, 0, 0);
11
        /* RGBa with 0.5 opacity */
12
        background:rgba(0, 0, 0, 0.5);        
13
    }
14
</style>
15
</head>
16
<body>        
17
    <p><strong>Warning:</strong> Internet Explorer 8 and earlier version doesn't support the RGBA colors.</p>
18
</body>
19
</html>
 

在微博、微信、公众号、小程序分享此示例。 如果您觉得有帮助,请给我们一个赞。