views:

401

answers:

1

Can anyone point me in the right direction for adding a remember me checkbox for a simple login page? It basically only uses a password, not a user name. Is this possible?

Here's the code for the unprotected part of the login asp page:

'****************** Begin UNprotected content ****************************
'
'   Enter the content you want the user to see prior to loggin in here.
'   Be sure the content is between the < % Else % > and < % End If % > asp
'   tags here. 

%>
<p>Welcome to our Members Only area. Please enter the password we supplied you to Log
In.</p>
<form action="<%= strPage %>" method="post" name="frmMembers" id="frmMembers">
<table id="n3-LogInTable">
 <caption><%= strCaption %></caption>
 <col class="colOne" />
 <col />

 <tr>
  <td nowrap="nowrap">Password</td>
  <td><input name="txtPassword" type="password" class="n3-textField" id="txtPassword" size="30" maxlength="50" /></td>
 </tr>
 <tr>
  <td colspan="2" nowrap="nowrap"><input name="btnLogIn" type="image" id="btnLogIn" src="login/n3_stuff/btn_login.gif" /></td>
 </tr>
 <tr></tr>
</table>
</form>
<% '****************** End UNprotected content ****************************
+1  A: 

Use a cookie http://bytes.com/groups/net-asp/442519-remember-me-cookie-asp-net

Chris Ballance
Thanks, but I need to know how to do this from the start, as in creating the code for the checkbox itself.Thanks.