Go Back   CodingForums.com > :: Server side development > ASP

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 07-16-2004, 07:09 AM   PM User | #1
patel
New to the CF scene

 
Join Date: Jul 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
patel is an unknown quantity at this point
Question kindergarten ASP

hai ppl of the forum...i am very new to ASP...and i need help on that....

I am creating a form system for my uni project...i need to know hw to post values from the form into the database....i am using a Access.....my form has the following fields to be input into the database...Name, Age, Address, Tel No....

I also need to know hw to validate password....i mean authenticate password.....

It might be a simple question but i a really really new.....

please help!!!!!!!!!!
patel is offline   Reply With Quote
Old 07-16-2004, 08:13 AM   PM User | #2
glenngv
Supreme Master coder!


 
glenngv's Avatar
 
Join Date: Jun 2002
Location: Los Angeles, CA Original Location: Philippines
Posts: 10,241
Thanks: 0
Thanked 112 Times in 111 Posts
glenngv will become famous soon enough
Google is our friend.

http://www.tutorial-web.com/asp/database/sql.asp
http://www.1asphost.com/asp_db.asp
__________________
Glenn
_____________________________________________
Play Tower of Hanoi Android app (Ad-FREE!)
Play Tower of Hanoi Android app (FREE!)
Go to Tower of Hanoi Leaderboard
Play Tower of Hanoi Facebook app
glenngv is offline   Reply With Quote
Old 07-16-2004, 09:09 AM   PM User | #3
Bullschmidt
Regular Coder

 
Join Date: Aug 2002
Location: USA
Posts: 478
Thanks: 0
Thanked 2 Times in 2 Posts
Bullschmidt is an unknown quantity at this point
www.asp101.com/samples has some short database examples

And here's the basic concept of a login page:

Classic ASP Design Tips - Login Page
http://www.bullschmidt.com/devtip-loginpage.asp

Perhaps have a login page that asks the user for his username and password. And whatever page that posts to (which could be the same page for a self posting form) tests these fields against what is in the database, sets the username and userlevel session variables accordingly, and then redirects to the proper page - i.e. back to the login page if the password is wrong (perhaps with a JavaScript popup saying wrong username/password combination) or to the main menu page if the password is correct:

Session("UserName") = objRS("UserName")
Session("UserLevel") = objRS("UserLevel")
Response.Redirect "mainmenu.asp"

Then you can use If Then's or Select Case on each page to control whether a user is allowed to actually be there and whether particular links of where a user can go actually show up.

If (Session("UserLevel") <> "Admin") And (Session("UserLevel") <> "Regular") Then
Response.Redirect "login.asp"
End If
__________________
J. Paul Schmidt
www.Bullschmidt.com - Freelance Web and Database Developer
www.Bullschmidt.com/DevTip.asp - Classic ASP Design Tips
Bullschmidt is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 08:24 PM.


Advertisement
Log in to turn off these ads.