| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 465 人关注过本帖
标题:登陆代码 挑错 倒插鸡毛
取消只看楼主 加入收藏
土匪00fa
Rank: 1
等 级:新手上路
帖 子:4
专家分:0
注 册:2011-4-3
结帖率:100%
收藏
已结贴  问题点数:20 回复次数:0 
登陆代码 挑错 倒插鸡毛
我自己做的一个留言板 不知道那错啦
!库名是date 表名是student

<!--#include file="conn.asp"-->
<%
dim sql
dim name
dim password
name=trim(request("name"))
password=trim(Request("password"))
set rs=server.createobject("adodb.recordset")
sql="select * from student where name='" & username & "' and password='" & password &"'"
rs.open sql,conn,1,3
if not(rs.bof and rs.eof) then
 if  password=rs("password") then
        session("Name")=rs("name")  
  Response.Redirect "eee.asp"
 end if
end if
Response.Write("<script language=""JavaScript"">alert(""用户名或密码错误!!"");history.go(-1);</script>")
rs.close
conn.close
set rs=nothing
set conn=nothing
%>
搜索更多相关主题的帖子: 留言板 Request where 
2011-04-24 14:48
快速回复:登陆代码 挑错 倒插鸡毛
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.014924 second(s), 8 queries.
Copyright©2004-2025, BC-CN.NET, All Rights Reserved