ASP用户登陆系统 登陆后 不能自动跳转index.asp页面
代码:Dim Action
Action=CheckStr(Request.QueryString("Action"))
Select Case Action
Case "savepassword"
Call checkuser()
Call savepassword()
Case "modifypassword"
Call checkuser()
Call ModifyPassWord()
Case "chklogin"
Call chklogin() '-----------------------定义用户登陆界面
Sub chklogin()
if Dreamsun_name<> "" Then response.redirect "index.asp"
%>
<form name="save" method="post" action="user.asp?Action=chklogin" onSubmit="return regcheck(this);">
<br><br>
<table width="600" border=0 align="center" cellPadding=0 cellSpacing=1 class="zd_table" id="form2">
<tr class="zd_td">
<td height="30" align="center" colspan=2><strong>用户登录</strong></td>
</tr>
<tr class="zd_td">
<td width="30%" height="30" align="right"><strong>帐 号:</strong></td>
<td> <input name="username" type="text" id="username" size="20" maxlength="20"> <span id="formct_username"></span></td>
</tr>
<tr class="zd_td">
<td height="30" align="right"><strong>密 码:</strong></td>
<td> <input name="pwd" type="password" id="pwd" size="20" maxlength="20"> <span id="formct_pwd"></span></td>
</tr>
<%If Session(webname&"_logintimes")<>"" Then %>
<tr class="zd_td">
<td height="30" align="right"><strong>验证码:</strong></td>
<td> <input name="zd_code" type="text" id="zd_code" size="4" maxlength="4" onKeyPress="if ((event.keyCode<48 &&event.keyCode!=13) || event.keyCode>57) event.returnValue=false" onFocus="document.all.checkcode.src='inc/GetCode.asp?a=login&s='+Math.random()"/>
<img id='checkcode' src="images/circle.gif" alt= "验证码,看不清楚?请点击刷新验证码" style="cursor : pointer;" onclick="src='inc/GetCode.asp?a=login&s='+Math.random()"/> <span id="formct_zdcode"></span>
</td>
</tr>
<%End If %>
<tr class="zd_td">
<td height="30" align="right"><strong>保留登录:</strong></td>
<td> <input type='radio' name='baoliu' value='' checked>否 <input type='radio' name='baoliu' value='365'>是</td>
</tr>
<tr class="zd_td">
<td height="30" align="right"> </td>
<td><input name="submit3" type=button value='注册' onClick="window.location='user.asp?Action=reg'">
<input name="comurl" type="hidden" id="comurl" value="<%=Cstr(Request.ServerVariables("HTTP_REFERER"))%>">
<input type=submit name=login id=login value="登录" >
</tr>
</table&g