www.gusucode.com > 绿色环保工作企业网站源码程序 > UserReg.asp

    <!--#include file="Inc/SysProduct.asp" -->
<!-- #include file="Head.asp" -->
<script language=javascript>
function checkreg()
{
  if (document.UserReg.UserName.value=="")
	{
	alert("请输入用户名!");
	document.UserReg.UserName.focus();
	return false;
	}
  else
    {
	document.reg.username.value=document.UserReg.UserName.value;
	var popupWin = window.open('UserCheckReg.asp', 'CheckReg', 'scrollbars=no,width=340,height=200');
	document.reg.submit();
	}
}
</script>
<TABLE cellSpacing=0 cellPadding=0 width=1002 align=center border=0>
  <TBODY>
    <TR>
      <TD vAlign=top width=210><TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
          <TBODY>
            <TR>
              <TD><IMG height=40 src="imgbly/lt29.gif" width=210></TD>
            </TR>
            <TR>
              <TD align=middle><TABLE 
            style="BORDER-RIGHT: #e9e9e9 1px solid; BORDER-TOP: #e9e9e9 1px solid; BORDER-LEFT: #e9e9e9 1px solid; BORDER-BOTTOM: #e9e9e9 1px solid" 
            cellSpacing=0 cellPadding=0 width=178 border=0>
                <TBODY>
                  <TR>
                    <TD height=15>&nbsp;</TD>
                  </TR>
                  <TR>
                    <TD><TABLE cellSpacing=0 cellPadding=0 width=162 align=center 
                  border=0>
                        <TBODY>
                          <TR>
                            <TD class=lNav1><a href="UserEdit.asp">修改会员资料</a></TD>
                          </TR>
                          <TR>
                            <TD class=lNav><a href="UserEditPwd.asp">修改会员密码</a></TD>
                          </TR>
                          <TR>
                            <TD class=lNav><a href="UserOrder.asp">购物订单查询</a></TD>
                          </TR>
                          <TR>
                            <TD class=lNav><a href="FeedbackMember.asp">站内留言中心</a></TD>
                          </TR>
                          <TR>
                            <TD class=lNav><a href="UserLogout.asp?Action=Ch">退出会员中心</a></TD>
                          </TR>
                        </TBODY>
                    </TABLE></TD>
                  </TR>
                  <TR>
                    <TD height=15>&nbsp;</TD>
                  </TR>
                </TBODY>
              </TABLE></TD>
            </TR>
          </TBODY>
        </TABLE>
          <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
            <TBODY>
              <TR>
                <TD><IMG height=38 src="imgbly/tit_sel.gif" width=210></TD>
              </TR>
              <TR>
                <TD align=middle><table width="180" border=0 align="center" cellpadding=0 
                        cellspacing=1 
                        style="BORDER-RIGHT: #e3e3e3 1px solid; BORDER-TOP: #e3e3e3 1px solid; BORDER-LEFT: #e3e3e3 1px solid; BORDER-BOTTOM: #e3e3e3 1px solid">
                    <tbody>
                      <tr>
                        <td style="PADDING-BOTTOM: 8px; PADDING-TOP: 8px"><table border="0" cellpadding="2" cellspacing="0" align="center">
                            <form method="Get" name="myform" action="search.asp">
                              <tr>
                                <td height="28"><input type="text" name="keyword"  style="BORDER-RIGHT: #b7b7b7 1px solid; BORDER-TOP: #b7b7b7 1px solid; BORDER-LEFT: #b7b7b7 1px solid; WIDTH: 120px; BORDER-BOTTOM: #b7b7b7 1px solid" size=12 value="关键字" maxlength="50" onFocus="this.select();">
                                    <input type="submit" name="Submit"  value="搜索">
                                </td>
                              </tr>
                            </form>
                        </table></td>
                      </tr>
                  </table></TD>
              </TR>
            </TABLE>
          <SCRIPT type=text/ecmascript>
function doLogin(fm){
   if(fm.uid.value=='' || fm.uid.value.indexOf("\'")!=-1){
		alert('对不起,用户名不能为空或含有单引号!');
		fm.uid.focus();
		return false;   			
   }
   if(fm.pwd.value==''){
		alert('对不起,密码不能为空!');
		fm.pwd.focus();
		return false;   			
   }

	var postData="Act=doLogin&uid="+escape(fm.uid.value)+"&pwd="+escape(fm.pwd.value);
	var loginAjax=new sc.Ajax("doLogin.asp", "GET", postData);
	loginAjax.addEventListener(loginEvent);
	loginAjax.Exec();

	function loginEvent(){
		var a=loginAjax.ajax;
		if(a.readyState==4){ 
			if(a.status==200){
				var rtn=a.responseText;
				if(rtn==1){
					alert('恭喜,您己经登录成功!');
					document.location.reload();
				}else{
					alert('对不起,登录失败!用户名/密码错。');
				}
			}else{
				alert("抱歉,服务器忙,请稍后再试..."+a.statusText );
			}
		}
	}
	return false;
}

function doLogout(){
  var loginAjax=new sc.Ajax('doLogin.asp', 'GET', 'Act=doLogout');
  loginAjax.addEventListener(logoutEvent);
  loginAjax.Exec();

	function logoutEvent(){
		var a=loginAjax.ajax;
		if(a.readyState==4){ 
			if(a.status==200){
				var rtn=a.responseText;
				if(rtn==1){
					alert('确定要退出吗!');
					document.location.href=".";
				}else{
					alert('对不起,退出失败!');
				}
			}else{
				alert("抱歉,服务器忙,请稍后再试..."+a.statusText );
			}
		}
	}
}

  </SCRIPT>
          <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
            <TBODY>
              <TR>
                <TD><IMG height=38 src="imgbly/tit_mem.gif" width=211></TD>
              </TR>
              <TR>
                <TD align=middle><TABLE 
            style="BORDER-RIGHT: #e3e3e3 1px solid; BORDER-TOP: #e3e3e3 1px solid; BORDER-LEFT: #e3e3e3 1px solid; BORDER-BOTTOM: #e3e3e3 1px solid" 
            cellSpacing=1 cellPadding=0 width=178 align=center border=0>
                    <TBODY>
                      <TR>
                        <TD align="center" 
                style="PADDING-RIGHT: 5px; PADDING-LEFT: 2px; PADDING-BOTTOM: 5px; PADDING-TOP: 6px"><% call ShowUserLogin() %></TD>
                      </TR>
                  </TABLE></TD>
              </TR>
            </TBODY>
        </TABLE></TD>
      <TD style="BACKGROUND: url(imgbly/bg_body.gif) repeat-y 50% top" vAlign=top><TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
          <TBODY>
            <TR>
              <TD><TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
                  <TBODY>
                    <TR>
                      <TD background=imgbly/bg_rt.gif><TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
                          <TBODY>
                            <TR>
                              <TD><IMG src="imgbly/rt20.gif" width="209" height=41></TD>
                              <TD>&nbsp;</TD>
                              <TD class=loc 
                      style="BACKGROUND: url(img/bg_rtjiao.gif) no-repeat right 50%; COLOR: #9f9f9f" 
                      align=right>你现在的位置:<A href="index.asp">首页</A> &gt; <A 
                        href="about.asp">用户注册</A></TD>
                            </TR>
                          </TBODY>
                      </TABLE></TD>
                      <TD width=17>&nbsp;</TD>
                    </TR>
                  </TBODY>
              </TABLE></TD>
            </TR>
          </TBODY>
        </TABLE>
          <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
            <TBODY>
              <TR>
                <TD width=17 height=15>&nbsp;</TD>
                <TD>&nbsp;</TD>
                <TD width=17>&nbsp;</TD>
              </TR>
              <TR>
                <TD>&nbsp;</TD>
                <TD style="LINE-HEIGHT: 24px"><table width="100%" border="0" cellspacing="0" cellpadding="0">
                    
            <TR> 
              <TD height="1"> <FORM name='UserReg' action='UserRegPost.asp' method='post'>
                          <table width=95% border=0 align="center" cellpadding=5 cellspacing=1 bordercolor="#FFFFFF" style="border-collapse: collapse">
                            <TR align=center> 
                              <TD height=20 colSpan=2><b>新用户注册</b></TD>
                            </TR>
                            <TR> 
                              <TD width="35%"><b>用户名:</b><BR>
                                不能小于4个字符(2个汉字)</TD>
                              <TD width="65%"> <INPUT   maxLength=14 size=30 name=UserName>
                                <font color="#FF0000">*</font>  <input name="Check" type="button" id="Check" value="检查用户名" onClick="checkreg();"></TD>
                            </TR>
                            <TR> 
                              <TD width="35%"><B>密码(至少6位):</B><BR>
                                请输入密码,区分大小写。 不要使用类似 '*'、' '的特殊字符</TD>
                              <TD width="65%"> <INPUT   type=password maxLength=12 size=30 name=Password> 
                                <font color="#FF0000">*</font> </TD>
                            </TR>
                            <TR> 
                              <TD width="35%"><strong>确认密码(至少6位):</strong><BR> 
                              </TD>
                              <TD width="65%"> <INPUT   type=password maxLength=12 size=30 name=PwdConfirm> 
                                <font color="#FF0000">*</font> </TD>
                            </TR>
                            <TR> 
                              <TD width="35%"><strong>密码问题:</strong><BR>
                                忘记密码的提示问题</TD>
                              <TD width="65%"> <INPUT   type=text maxLength=50 size=30 name="Question"> 
                                <font color="#FF0000">*</font> </TD>
                            </TR>
                            <TR> 
                              <TD width="35%"><strong>问题答案:</strong><BR>
                                忘记密码的提示问题答案,用于取回密码</TD>
                              <TD width="65%"> <INPUT   type=text maxLength=20 size=30 name="Answer"> 
                                <font color="#FF0000">*</font> </TD>
                            </TR>
                            <TR> 
                              <TD width="35%"><strong>性别:</strong><BR>
                                请选择您的性别</TD>
                              <TD width="65%"> <INPUT type=radio CHECKED value="1" name=sex>
                                男 &nbsp;&nbsp; <INPUT type=radio value="0" name=sex>
                                女</TD>
                            </TR>
                            <TR> 
                              <TD width="35%"><strong>Email地址:</strong><BR>
                                请输入有效的邮件地址</TD>
                              <TD width="65%"> <INPUT   maxLength=50 size=30 name=Email> 
                                <font color="#FF0000">*</font></TD>
                            </TR>
                            <TR> 
                              <TD><strong>公司网址:</strong></TD>
                              <TD width="65%"><INPUT name=homepage id="homepage" value="http://" size=30   maxLength=50></TD>
                            </TR>
                            <TR> 
                              <TD width="35%"><strong>公司名称:</strong><BR>
                                您的公司名称</TD>
                              <TD width="65%"> <INPUT name=CompanyName id="CompanyName" size=30   maxLength=100></TD>
                            </TR>
                            <TR> 
                              <TD><strong>收货地址:</strong></TD>
                              <TD><INPUT name=Add id="Add" size=30   maxLength=100> 
                                <font color="#FF0000">*</font></TD>
                            </TR>
                            <TR> 
                              <TD><strong>收货人:</strong></TD>
                              <TD><INPUT name=Receiver id="Receiver" size=30   maxLength=100></TD>
                            </TR>
                            <TR> 
                              <TD><strong>邮政编码:</strong></TD>
                              <TD width="65%"><input name=postcode id="postcode" size=30 maxlength=20> 
                                <font color="#FF0000">*</font></TD>
                            </TR>
                            <TR> 
                              <TD><strong>联系电话:<br>
                                </strong>格式001-81991660<strong> </strong></TD>
                              <TD width="65%"><input name=Phone id="Phone" size=30 maxlength=20> 
                                <font color="#FF0000">*</font></TD>
                            </TR>
                            <TR>
                              <TD><strong>手机:</strong></TD>
                              <TD><input name=Mobile id="Mobile" size=30 maxlength=20></TD>
                            </TR>
                            <TR> 
                              <TD width="35%"><strong>传 真:</strong></TD>
                              <TD width="65%"> <INPUT name=Fax id="Fax" size=30 maxLength=50></TD>
                            </TR>
                          </TABLE>
                  <div align="center"> 
                    <INPUT   type=submit value=" 注 册 " name=Submit>
                    &nbsp; 
                    <INPUT name=Reset   type=reset id="Reset" value=" 清 除 ">
                  </div>
                </form>
				        <form name='reg' action='UserCheckreg.asp' method='post' target='CheckReg'>
          <input type='hidden' name='username' value=''>
        </form>
				</TD>
            </TR>
                  </table></TD>
                <TD>&nbsp;</TD>
              </TR>
              <TR>
                <TD height=10>&nbsp;</TD>
                <TD>&nbsp;</TD>
                <TD>&nbsp;</TD>
              </TR>
            </TBODY>
        </TABLE></TD>
    </TR>
  </TBODY>
</TABLE>
<!-- #include file="Inc/Foot.asp" -->
</BODY></HTML>