使用文本输入提示的方式验证贵美网站的注册页面

本文档展示了贵美商城注册页面的HTML和CSS代码,以及使用JavaScript进行文本输入验证的函数,包括名字、姓氏、Email和密码的验证。当用户在输入框失去焦点时,会检查输入内容是否为空、Email格式是否正确,密码长度是否至少为6个字符,以及确认密码是否与原始密码一致。
摘要由CSDN通过智能技术生成
<!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">
<head>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"	/>
 <title>贵美商城</title>
 <style type="text/css">
	body{
		border:0px;
		padding:0px;
		margin:0px auto;
		font:12px Tahoma;	
	}
	div,ul,li,dt,dl {
		float:left;
		margin:0px auto;
	  padding:0px;
		}
	li{
		list-style:none;	
		}
  a:link   {color:#333333;text-decoration: none;}   
  a:visited   {color:#333333;text-decoration: none;}   
  a:active   {color:#333333;text-decoration: none;}   
  a:hover   {color:#ff7300;} 	
	
	input {
		border:1px #333333 solid;
		margin:0px;
		padding:0px;
		}
		
		a img{
			border:0px;
			}
	
	.red {color:red;font-weight: bold;text-align:left;}		
	.b {font-weight:bold;}
	#container{
		width:980px;
		margin:0 auto;
		float:none;
		}
	

	#header { 
		width:980px;
		height:136px;
		margin:0px auto;
		background:url(./images/h_bg.jpg) no-repeat -22px 0px;
		}
	
		#logo {
		  width:250px;
		  height:108px;
		  float:left;
		  background:url(./images/h_bg.jpg) no-repeat -22px 0px;
			}
			

	  .upright_menu {
	  	float:right;padding:15px 20px 0px 0px;
	  	}
	    	.pic{width:28px;height:26px;}
	    	.pic1{background:url(./images/icon.gif) no-repeat;}
	    	.pic2{background:url(./images/icon.gif) no-repeat -28px 0px;}
	    	.pic3{background:url(./images/icon.gif) no-repeat -56px 0px;}
	    	.pic5{background:url(./images/icon.gif) no-repeat -84px 0px;}
	    	.pic6{background:url(./images/icon.gif) no-repeat -112px 0px;}	
	    	.h_text{padding:6px 5px 0px 5px; padding-top:8px\0;text-align:center;}
	      .login {background:url(./images/icon.gif) no-repeat 0px -25px;}      
	      .reg {background:url(./images/icon.gif) no-repeat 0px -25px;}
	      
	  .upright_bottom{width:600px;height:26px;float:right;padding:7px 0px 0px 0px;}      
	      .bt {width:38px;height:26px;}	   
	      .hello {padding:11px 33px 0px 0px;color:#636362;letter-spacing:3px;} 
	  .nav{width:980px;}
	  .nav li {
	  	width:84px;
	  	height:30px;
	  	float:left;
	  	text-align:center;
	  	font-weight:bold;
	  	}
	  .nav li a{padding:8px 10px;}
	  .nav li a:link,.nav li a:active,.nav li a:visited{ 	
	  	padding:8px 10px;
	  	color:#333333;
	  	font-size:13px;
	  	}
	  .nav li a:hover{	
	  	padding:8px 10px;
	  	background:url(./images/nav_bg.png) no-repeat !important;
	  	filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled="true",sizingMethod="scale",src="./images/nav_bg.png");
	  	_background-image:none;
	  	}  
	                                                                                                                                             

	#main{
		width:980px;
		margin:0 auto;
		border:0px;
		float:left;
		}      

	#left{
		width:204px;
		height:644px;
		padding:38px 0px 0px 0px;
		background:url(./images/bg.gif) no-repeat;	
		}   
	  
		.left_list,.right_list{padding:0px 10px 0px 13px;width:174px;}
		.left_class{
			font-size:14px;
			color:#ff7300;
			font-weight:bold;
			float:none;
			padding:9px 0px 0px 0px;
			}
		 .left_li{color:#636362;width:58px;line-height:24px;}
	
	
		 	
	.width_8px{width:8px;height:644px;}
	
	#content{
		width:527px;
		background:url(./images/bg.gif) no-repeat -212px 0px;
		} 
	  .content_top{width:527px;padding-top:8px;height:182px;}
	  
	  #adv1,#adv2,#adv3,#adv4{display:none; }
	  #adv {position:absolute;left:480px;top:315px;text-align:center;}
	  #adv a{
	     font-size:13px;
	     text-decoration:none;
	     background-color:#cccccc;
	     padding:0px 5px;
	   }	  
	   
	  .content_list{width:524px;height:449px;padding-top:58px;*padding-top:50px;}
	  .content_li{width:166px;padding:3px 0px;text-align:center;}
	  .content_img {width:142px;height:89px;float:none;text-align:center;}
	  

	#right{
		width:233px;

		height:644px;
		background:url(./images/bg.gif) no-repeat -747px 0px;
		} 	
		
		.right_list dl{padding:10px 10px 0px 0px;*width:190px;}
		.right_list dt{padding:0px 5px 0px 0px;}
		.right_list dd{line-height:17px;white-space:nowrap;}
	  .right_list img{border:1px solid #9ea0a2;}
	
		 	.r1{width:200px;height:170px;}
		 	.r2 dl dt img{width:60px;height:47px;}
		 	.r2 dd {padding-top:20px;}
	
	 	#tab{padding-top:14px;}
	 	#tabtitle1{cursor:pointer;width:80px;height:50px;background:url(images/bg.gif) no-repeat -761px -430px;}
	 	#tabtitle2{cursor:pointer;width:153px;height:50px;background:url(images/bg.gif) no-repeat -840px -430px;}
	 	#tab1,#tab2{display:none;}
 
	#footer{
		width:980px;
		height:150px;
		float:none;
		}
	  .copyright{width:980px;text-align:center;line-height:20px;}
	  .register_textBroader{width:125px;}

	#advLeft{
	  position:absolute;
	  height:74px;
	  width:74px;
	  z-index:1;	
		}
	#advRight{
	  position:absolute;
	  height:80px;
	  width:80px;
	  z-index:1;	
		}
		
	#closeLeft{
	  cursor:pointer;
	  position:absolute;
	  height:13px;
	  width:13px;
	  z-index:2;	
		}	
	
	#closeRight{
	  cursor:pointer;
	  position:absolute;
	  height:13px;
	  width:13px;
	  z-index:2;	
		}	

	.list_bg {background:url(./images/list_bg.gif) repeat-x;}
	.reg_text{width:130px;height:18px;margin:5px 5px; }
	

	.input_title{width:160px;text-align:right;}
	.input_content{width:507px;text-align:left;padding:5px 5px;}
	.reg_bg {background:url(./images/reg_bg.gif) repeat-x;}
	.login_bg {padding-top:50px;background:url(./images/login_bg.gif) repeat-x;}
	textarea{border:1px solid #cccccc;padding:5px;}
	

	.a_l{text-align:left;}
	.a_r{text-align:right;}
	.a_c{text-align:center;}
	
	.f_l{float:left;}
	.f_r{float:right;}
	.f_n{float:none;}
	
	/*input大小*/
	.n4{width:35px;}  
	
	.w3p{width:3%;}
	.w10p{width:10%;}
	.w15p{width:15%;}
	.w20p{width:20%;}
	.w25p{width:25%;}
	.w50p{width:50%;}
	.w63p{width:63%;}
	.w87p{width:87%;}
	
	.w9{width:9px;}
	.w84{width:84px;}
	.w81 {width:81px;}
	.w100{width:100px;}
	.w129 {width:129px;}
	.w252 {width:252px;}
	.w350{width:350px;}
	.w364{width:364px;}
	.w507{width:507px;}
	
	.h24 {height:24px;}
	.h32 {height:32px;}
	.h34 {height:34px;}
	.h35 {height:35px;}	
	.h40 {height:40px;}
	.h58 {height:58px;}
	.h65 {height:65px;}
	.h460 {height:460px;}
	
	.h20p {height:20%;}
	.h37p {height:37%;}
	.h43p {height:43%;}
	
	input checkbox{border:0;}
	.warn{color:red;}
</style>
<script type="text/javascript" src="js/jquery-1.11.1.js"></script>
<script type="text/javascript" src="js/jquery-migrate-1.2.0.js"><
  • 3
    点赞
  • 20
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值