css 区分 input 的类型 input[type…
2014-06-06 11:22
429 查看
css 区分 input 的类型 input[type="text"]
input[type="text"]{ border:1px; border-style:solid; border-color:
#CCCCCC; }
--------------------------------------------------
ie6 兼容
input[type="text"]{ border:1px; border-style: solid; border-color:
#CCCCCC; }
input{
border-color:expression_r(this.type=="text"?"#CCCCCC":"Default");
border:expression_r(this.type=="text"?"1px":"Default");
border-style:expression_r(this.type=="text"?"solid":"Default");
}
--------------------------------------------------
input[type="text"]{
--------------------------------------------------
<!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/html;
charset=gb2312" />
<title>无标题文档</title>
<style type="text/css">
input[type="text"]{
background-color:#FFC;}
input[type="password"]{
background-color:#339966;}
input[type="submit"]{
background-color:blue;
color:white;}
input[type="reset"]{
background-color:navy;
color:white;}
input[type="radio"]{
margin:10px;}
input[type="checkbox"]{
margin:10px;}
input[type="button"]{
background-color:lightblue;}
</style>
</head>
<body>
<dl>
<dt>textbox:<dd><input
type="text" value="www.66css.com">
<dt>password:<dd><input
type="password" value="www.66css.com">
<dt>submit:<dd><input
type="submit">
<dt>reset:<dd><input
type="reset">
<dt>radio:<dd><input
type="radio" name="ground1">
<dt>checkbox:<dd><input
type="checkbox" name="ground2">
<dt>button:<dd><input
type="button" value="www.66css.com">
</dl>
</body>
</html>
input[type="text"]{ border:1px; border-style:solid; border-color:
#CCCCCC; }
--------------------------------------------------
ie6 兼容
input[type="text"]{ border:1px; border-style: solid; border-color:
#CCCCCC; }
input{
border-color:expression_r(this.type=="text"?"#CCCCCC":"Default");
border:expression_r(this.type=="text"?"1px":"Default");
border-style:expression_r(this.type=="text"?"solid":"Default");
}
--------------------------------------------------
input[type="text"]{
--------------------------------------------------
<!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/html;
charset=gb2312" />
<title>无标题文档</title>
<style type="text/css">
input[type="text"]{
background-color:#FFC;}
input[type="password"]{
background-color:#339966;}
input[type="submit"]{
background-color:blue;
color:white;}
input[type="reset"]{
background-color:navy;
color:white;}
input[type="radio"]{
margin:10px;}
input[type="checkbox"]{
margin:10px;}
input[type="button"]{
background-color:lightblue;}
</style>
</head>
<body>
<dl>
<dt>textbox:<dd><input
type="text" value="www.66css.com">
<dt>password:<dd><input
type="password" value="www.66css.com">
<dt>submit:<dd><input
type="submit">
<dt>reset:<dd><input
type="reset">
<dt>radio:<dd><input
type="radio" name="ground1">
<dt>checkbox:<dd><input
type="checkbox" name="ground2">
<dt>button:<dd><input
type="button" value="www.66css.com">
</dl>
</body>
</html>
相关文章推荐
- css 区分 input 的类型 input[type="text"]
- css 区分 input 的类型 input[type="text"]
- css统一设置input样式(区分input类型)
- CSS定义input的type类型样式
- Html+CSS input type=file 文件类型限制属性 accept (HTML 5)
- css统一设置input样式(区分input类型)
- android:inputType设置文本类型
- 如何给 input 中 type="text" 设置css
- <input type="file" />浏览时只显示指定文件类型
- input type=file accept中可以限制的文件类型
- css style(input type="button")
- [转]css 怎样将input type=radio的边框去掉?
- android:inputType参数类型说明
- CSS美化 input type=file 兼容各个浏览器
- CSS美化 input type=”file” 兼容所有浏览器
- css style(about input type="text")
- [转]css 怎样将input type=radio的边框去掉?
- input type file 限定上传文件类型为txt
- CSS分别设置Input样式(按input类型)
- html的input几种type类型的内容。