简洁输入框样式

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf8" />
	<title>CSS美化的漂亮搜索框</title>
	<style type="text/css"> 
body{ 
font: normal 100% 'Arial','Helvetica','Verdana',sans-serif; 
color: #333; 
} 
p { 
padding: 12px 0; 
margin: 0; 
font-size: .8em; 
line-height: 1.5; 
} 
form { 
margin: 0; 
} 
#search_box { 
width: 201px; 
height: 31px; 
background: url(http://files.jb51.net/demoimg/200912/bg_search_box.gif); 
} 
#search_box #s { 
float: left; 
padding: 0; 
margin: 6px 0 0 6px; 
border: 0; 
width: 159px; 
background: none; 
font-size: .8em; 
} 
#search_box #go { 
float: right; 
margin: 3px 4px 0 0; 
} 

input,button,select,textarea
{
      outline:none;
      -webkit-appearance:none;
}
textarea
{
     resize:none;
}
</style>
</head>
<body>
	<div id="search_box">
		<form id="search_form" method="post" action="#">
			<input type="text" id="s" value="Search" class="swap_value" />
			<input type="image" src="http://files.jb51.net/demoimg/200912/btn_search_box.gif" width="27" height="24" id="go" alt="Search" title="Search" />
		</form>
	</div>
</body>
</html>


附上一点:如何清除浏览器自带的输入框样式

 
input,button,select,textarea
{
      outline:none;
      -webkit-appearance:none;
}
textarea
{
     resize:none;
}


 
  http://www.jb51.net/css/22930.html
  http://blog.sina.com.cn/s/blog_859df1330102v99m.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值