求ASP表单验证不能为空值的代码

2024-12-19 20:07:03
推荐回答(4个)
回答1:

login.asp里
<%
if request.form("username") <> "" and request.form("pwd")<> "" then
你原来的登录代码
else
response.redirect(request.servervariables("HTTP_REFER"))'返回前一页
end if %>

回答2:

login.asp
---------
<%
if request.form("username")="" or request.form("pwd")="" then
response.write ""
end if
%>

回答3:

回答4:

if request.form("username") <> "" and request.form("pwd")<> "" then
else