PDA

View Full Version : hmmmm...



Phip
08-10-2002, 11:42 PM
well i have no idea what i am doing much. i'm trying to learn asp, i already know php. how do i do this right?

<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<%
IF goSignup = "1" Then
Set ConnSQL = Server.CreateObject("ADOBD.Connection")
path = Server.MapPath("\") + "\db\user.mdb"
ConnSQL.Open "Driver={Microsoft Access Driver (*.mdb)}; DBQ = " & path

sql = "INSERT INTO user_key (id, username, password, email) VALUES ('', request.QueryString(username), request.QueryString(password), 'phipx@chronicyouth.com')"
Set RS = server.CreateObject("adodb.recordset")
Set RS = ConnSQL.Execute(sql)

END IF
%>
<body>
<form action="index.asp" method="get" name="signup" target="_top">
username :
<input name="username" type="text" id="username">
<br>
password:
<input name="password" type="password" id="password">
<input name="goSignup" type="hidden" id="goSignup" value="1">
<br>
<input type="submit" name="Submit" value="Submit">
</form>
<br><br>
<%
getSql = "SELECT * FROM user_key WHERE id = '1'"
response.Write(getSQL)
Conn.Execute(getSQL)
%>
</body>

Phip
08-11-2002, 09:24 AM
it's hard to learn ASP. everyone hates and everyone who uses. geez.... i figured i out, by the way.

raf
08-13-2002, 10:19 AM
I'm a bit confused.

What are you exactly trying to do ? (Insert a new user and then showing him a login-form ? And then showing your sql statement to the user ?)

Perhaps, if you tell us what you are trying to do, we can help you out.

whammy
08-14-2002, 12:54 AM
I have a pretty basic registration/login script in ASP on my website - It requires someone to respond to a confirmation email before they can log in.

I made it as simple as I could with a lot of notes if you want to check it out!

Phip
08-14-2002, 01:33 AM
well i figured it out. but i started asp a while ago then "everyone" told me php was better and stuff. i think it is. but microsoft is where the money is, my opinion. i'm also a IT coordinator for a school they use microsoft access for a lot.

well anyway, i am back for more asp, why not? i was trying make a code that would be a basic sign up into a access database.

i figured it out though. thanks anyway. :)

whammy
08-14-2002, 01:36 AM
PHP in my opinion, is a bit better... especially in combination with a MySQL database... just seems a lot faster to me if everything is configured right (but I'm still working on PHP).

From what I've seen there are still a lot more job openings for ASP programmers, and the good thing is if you know one programming language, you really know them all (basically), minus some syntax and proprietary stuff - so learn one, and learn another, and learn some others, and you really have it made... that's what I'm working on... although I'll never catch up with some of the younger guys here. ;)