make sure sanatize your inputs to protect against sql injection.
as for the login, just change your query to:
SELECT * FROM logins WHERE uname='$uname' AND password='$pword'
also, a better way to do a login script is to see the number of results returned from the query.
ex.
//run query here
if (mysql_num_rows($result) == 1) {
//then log the person in
}
else {
//they have invalid credentials
}
kkeith29
Nearly a Posting Virtuoso
1,357 posts since Jun 2007
Reputation Points: 235
Solved Threads: 194
kkeith29
Nearly a Posting Virtuoso
1,357 posts since Jun 2007
Reputation Points: 235
Solved Threads: 194
Well, yes, sessions, but is there way to save user identification for long time? (except session in database/files/cookies)
Maybe some new clever way? I know the ordinary one's.
I don't think so..
nav33n
Purple hazed!
4,465 posts since Nov 2007
Reputation Points: 524
Solved Threads: 356
Yes I do have one. Please pm to get the bulk coupon.
Anybody interested in buying itechbids v7.0 @ 10% discount? Please use
my reseller coupon: RES3215.
I wonder why the mods haven't banned you yet.
nav33n
Purple hazed!
4,465 posts since Nov 2007
Reputation Points: 524
Solved Threads: 356