CSS设置文章字体颜色为白色?

html-css09

CSS设置文章字体颜色为白色?,第1张

<!DOCTYPE html>

<html lang="en">

<head>

<meta charset="UTF-8">

<title>景安</title>

<style type="text/css">

     .zzidc{color: whitebackground: redwidth: 200pxheight: 100px}

</style>

</head>

<body>

<div class="zzidc">设置字体白色</div>

</body>

</html>

css中,可以使用color属性来设置文章的颜色

白色有几种表示方法

1.white

2.#fff

3.#ffffff

4.rgb(255,255,255)

5.rgba(255,255,255,1)

楼主是对整个登录div设置了opacity,因此整个登录框都是半透明的。\x0d\x0a\x0d\x0a其实只需要给这个白色background的登录框改一下background-color就可以了:\x0d\x0a.login{\x0d\x0abackground-color:rgba(255,255,255,.5)\x0d\x0a\x0d\x0a}