<table width="192" border="0" align="center" cellpadding="2" cellspacing="0" background="image/block_2.gif">
<%if request.Cookies("bjx")("username")=""  then%>
<form name="userlogin" method="post" action="checkuserlogin.asp">
<tr> 
<td align="center"><font color="#999999">顾客您好,购买商品请先登录</font></td>
</tr>
<tr> 
<td align="center">用户名： 
<input type="text" class="wenbenkuang" name="username" size="14">
</td>
</tr>
<tr> 
<td align="center">密　码： 
<input type="password" class="wenbenkuang" name="userpassword" size="14">
</td>
</tr>
<tr> 
<td align="center">验证码： 
<input class=wenbenkuang name=verifycode type=text value="<%If GetCode=9999 Then Response.Write "9999"%>" maxLength=4 size=6>
<img src=GetCode.asp>
</td>
</tr>
<tr> 
<td align="center" height="38"> 
<input class=go-wenbenkuang name="imageField" value="登 陆" type=submit onFocus="this.blur()">
<input class=go-wenbenkuang onclick="window.location='reg.asp'" type=reset value="注 册" name=Submit2>
<input class=go-wenbenkuang onclick="window.location='getpwd.asp'" type=button value="忘 密" name=Submit3>
</td>
</tr>
</form>
<%else%>
<tr>
  <td align="center" height="38"><%
set rs=server.createobject("adodb.recordset")
rs.open "select jifen,yucun,reglx,vipdate from [user] where username='"&request.Cookies("bjx")("username")&"'",conn,1,3
if rs("vipdate")<>"" then 
'看是不是过期VIP
if rs("vipdate")<date and rs("reglx")=2 then
rs("reglx")=1
rs.update
end if
end if
response.Cookies("bjx")("yucun")=rs("yucun")
response.Cookies("bjx")("jifen")=rs("jifen")
response.Cookies("bjx")("reglx=")=rs("reglx")
rs.close
set rs=nothing
if request.Cookies("bjx")("reglx")=2 then
response.write ""&request.Cookies("bjx")("username")&" 贵宾您好<br>您目前有"&request.Cookies("bjx")("jifen")&"积分,预存款"&request.Cookies("bjx")("yucun")&"元 "
else
response.write ""&request.Cookies("bjx")("username")&" 您好<br>您目前有"&request.Cookies("bjx")("jifen")&"积分,预存款"&request.Cookies("bjx")("yucun")&"元 "
end if
response.write "<br><a href=user.asp><font color=red>进入会员中心</font></a>"
response.write "<br><a href=logout.asp>注销退出</a>"
end if
%></td>
</tr>
<tr>
  <td height="16" align="center" background="image/block_3.gif"></td>
</tr>
</table>
