<span style="color:#ff0000">红色</span>
在RGB颜色里,在后面四个为0的情况下,ff-00不断变化,红色不断加深。
如:
<span style="color:#ff0000">红色</span>
<span style="color:#ee0000">红色</span>
<span style="color:#dd0000">红色</span>
<span style="color:#cc0000">红色</span>
<span style="color:#990000">红色</span>
给确认按钮加一个css样式:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/htmlcharset=utf-8" />
<title>无标题文档</title>
<style>
.btn{background:#f00}
</style>
</head>
<body>
<label>
<input name="button" type="submit" class="btn" id="button" value="确认" />
</label>
</body>
</html>
补充一下,这个是按钮背景变成红色,要是字体颜色可以在样式里面写成:color:#f00