(编辑:jimmy 日期: 2024/10/31 浏览:2)
html
复制代码代码如下:
<link href="test.css" type="text/css" rel="stylesheet" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<div class="loginbox">
<h2>邮箱登录</h2>
<ul>
<li><input type="text" value="邮箱账号" class="account" /><input type="button" value="@qq.com" class="mail_btn" /></li>
<li><input type="text" value="密码" /></li>
</ul>
</div>
使用border-radius属性,制作圆角
复制代码代码如下:
/*CSS3.0圆角属性实现表单元素圆角*/
.loginbox{
background:#edf6ff;
border-left:1px solid #acc3e3;
border-right:1px solid #acc3e3;
padding:20px;
}
.loginbox h2{
color:#28456f;
font-size:14px;
}
.loginbox ul{
margin-top:10px;
}
.loginbox li{
margin-bottom:10px;
list-style-type:none;
}
.loginbox li input{
border:1px solid #9dadc6;
border-radius:6px;
height:32px;
padding:0 5px;
color:#888;
width:292px;
}
.loginbox li input.account{
width:182px;
border-right:1px solid #d5deed;
border-top-right-radius:0;
border-bottom-right-radius:0;
background:-moz-linear-gradient( top,#ddd 0%,#eee 10%,#fff 20%);
background:-webkit-linear-gradient( top,#ddd 0%,#eee 10%,#fff 20%);
background:-ms-linear-gradient( top,#ddd 0%,#eee 10%,#fff 20%);
}
.loginbox li input.mail_btn{
width:110px;
height:34px;
border-top-left-radius:0;
border-bottom-left-radius:0;
color:#504c4d;
text-align:left;
cursor:pointer;
}
代码很简洁,效果却很棒,CSS3你值得拥有!!!!