DW+ACCESS登陆代码

来源:百度知道 编辑:UC知道 时间:2024/06/15 19:25:11
小弟在做一个登陆界面,DW+ACCESS2000,想通过代码实现用户登陆,使用session函数,语句如下:
<%session("userid")=request.form("txtuserid")%>
但是在用如下语句输出userid的时候,却什么也没有,输出语句:
<%= session("userid") %>
有没有做过这方面的兄弟,小弟跪求,要自己写的代码,不要那种网上粘贴过来的。
下面是登陆页面的代码
<head>

<%
session("userid")=cstr(request.Form("txtuserid"))
session("userpw")=cstr(request.Form("txtuserpw"))
%>

<title>用户登陆</title>
</head>

<body>
<form id="form1" name="form1" method="post" action="main.asp">
<label>
<input type="text" name="txtuserid" id="txtuserid" />
<br />
</label>
<label>
<input type="text" name="txtuserpw" id="txtuserpw" />
<br /&g

<input type="submit" name="cmdcancel" id="cmdcancel" value="取消" />
改成<input type="reset" name="cmdcancel" id="cmdcancel" value="取消" />

==========================================================

到这里学一下吧!这个讲得很清楚的!!只要几分钟!看一下再否决好与坏!

http://ty502.com/10.html

试试吧!