主要用到CSS3box-shadow属性
工具/原料
CSS3box-shadow
方法/步骤
1、编写一个from表单<form><pclass=&qu艺皱麾酪ot;name"><造婷用痃labelfor="name">姓名</label><inputtype="text"name="name"id="name"/></p><pclass="email"><labelfor="email">邮箱</label><inputtype="text"name="email"id="email"/></p><pclass="submit"><inputtype="submit"value="提交"/></p></form>
2、<inputtype="email"name="email"id="email"/>type="email"是html新特性,监控输入文字是否是email
3、定义CSS样式<styletype="挢旗扦渌;text/css">input,textare锾攒揉敫a{padding:4px;border:solid1px#E5E5E5;outline:0;font:normal13px/100%Verdana,Tahoma,sans-serif;width:200px;background:#FFFFFF;box-shadow:rgba(0,0,0,0.1)0px0px8px;-moz-box-shadow:rgba(0,0,0,0.1)0px0px8px;-webkit-box-shadow:rgba(0,0,0,0.1)0px0px8px;}</style>
4、设置鼠标划过事件input:hover,textarea:hover,input:focus,textarea:focus{border-color:#C9C9C9;}label{margin-left:10px;color:#999999;display:block;}
5、设置submit属性.submitinput{width:auto;padding:9px15px;background:#617798;border:0;font-size:14px;color:#FFFFFF;}
6、漂亮的input生成了