March 13th, 2012, 12:49 AM
Member registration DB/users can't log in
The problem: I have some php pages that make up a simple user registration, login, member area, and logout. Newly registered users are added to the database successfully but they can not log in.
The details: I have been following a pretty basic guide located here: knowledgesutra.com/discuss/tlddl-php-simple-login-tutorial-learn-simple-login.html
The php that has been taken from that site has not been modified in any way, so I will not clutter this thread with the code -- it can be viewed by using the link above. You'll need to put an "http" for that link to work (yep I'm dancing around the rules... this may be my first post but I have to give out some URLs here in order to fully describe the problem.)
If the script can not match up the login details to the database, the it echos Sorry, could not log you in. Wrong login information. This is what is happening to me now.
I already checked for the obvious... The values in my config.php are correct and it is establishing a connection to the database. The user name, password and email I registered with to test it can be seen in the database, and I am using those exact values to attempt to log in. I deleted and remade the table twice.
I took two screen shots of the MySQL database for ease in solving this problem:
March 13th, 2012, 11:33 AM
If you're still having problems viewing those links I tried to post just let me know and I'll come up with a way to provide you the relevant information we're gonna need to solve this.
Not letting new comers to the forum post URLS is not very newbie friendly.
March 13th, 2012, 12:04 PM
yeah, but smart newbies will find a way
Originally Posted by Goshinki
remember, your average spammer isn't very smart at all
March 13th, 2012, 05:45 PM
I suggest finding a different tutorial, I glanced over the code at saw at least two serious and obvious security vulnerabilities in it. To be honest, it's not really worth debugging that one when there are much better tutorials available elsewhere. The fact that that tutorial shows up as the second result when you Google "PHP login tutorial" is sort of a tragic reflection on the average quality of PHP developers.
The first Google result has one of those same vulnerabilities in it too...
... and so does the 6th one.
OK, screw that, I will write you a tutorial.
This thread can be moved to the PHP forum.
March 13th, 2012, 06:52 PM
That'd be awesome... it's totally needed to. To be honest I thought the guide wasn't the best possible solution to what I'm trying to do but I searched for a long time before even finding a decent, simple one.
Originally Posted by E-Oreo
March 13th, 2012, 08:32 PM