ASP
  Home arrow ASP arrow Page 6 - Hey... I Remember You!
Dev Articles Forums 
ADO.NET  
Apache  
ASP  
ASP.NET  
C#  
C++  
ColdFusion  
COM/COM+  
Delphi-Kylix  
Design Usability  
Development Cycles  
DHTML  
Embedded Tools  
Flash  
Graphic Design  
HTML  
IIS  
Interviews  
Java  
JavaScript  
MySQL  
Oracle  
Photoshop  
PHP  
Reviews  
Ruby-on-Rails  
SQL  
SQL Server  
Style Sheets  
VB.Net  
Visual Basic  
Web Authoring  
Web Services  
Web Standards  
XML  
Dedicated Servers  
Moblin 
JMSL Numerical Library 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
ASP

Hey... I Remember You!
By: Mitchell Harper
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 3
    2001-11-15

    Table of Contents:
  • Hey... I Remember You!
  • Storing the users login details
  • Adding new users
  • Creating the login page
  • The CheckLogin routine
  • The "remember me" part
  • Conclusion

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Hey... I Remember You! - The "remember me" part


    (Page 6 of 7 )

    We can now create new user accounts and they can login. They can also choose to be remembered by checking the “Remember Me” box, which sets two cookies: u (username) and p (password).

    To complete our project, we will have to make a couple of modifications to the login.asp script. The code below will automatically fill out the login form with the cookies of the users username and password. If there is no cookie, the username and password fields will take the default value of “” (empty). The “Remember Me” checkbox will also be selected:

    26. Username: <input type="text" name="uname" maxlength="20" value="<%=Request.Cookies("u")%>">

    27. Password: <input type="password" name="pass" maxlength="20" value="<%=Request.Cookies("p")%>">

    28. <input type="checkbox" name="remember" value="ON" checked> Remember Me


    To test our application, fire up the adduser.asp page in your browser and create a new user with username “test” and password “go”. Jump to login.asp, enter the username “test” and password “go” and make sure the “Remember Me” checkbox is selected. Click the “Login Now” button.

    Next, close the web browser. Re-Open it and goto login.asp. Notice your username and password fields are automatically filled in! To get rid of them, click on the “Login Now” button with the “Remember Me” checkbox not selected.

    The process of adding a new user, logging in and r

    More ASP Articles
    More By Mitchell Harper


     

    ASP ARTICLES

    - Central Scoreboard with Flash and ASP
    - Calorie Counter Using WAP and ASP
    - Creating PGP-Encrypted E-Mails Using ASP
    - Be My Guest in ASP
    - Session Replacement in ASP
    - Securing ASP Data Access Credentials Using t...
    - The Not So Ordinary Address Book
    - Adding and Displaying Data Easily via ASP an...
    - Sending Email From a Form in ASP
    - Adding Member Services in ASP
    - Removing Unconfirmed Members
    - Trapping HTTP 500.100 - Internal Server Error
    - So Many Rows, So Little Time! - Case Study
    - XDO: An XML Engine Class for Classic ASP
    - Credit Card Fraud Prevention Using ASP and C...







    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway