rite, im hopeless at php/mysql, im learning a bit in about 3 weeks at uni but not gonna be soon enough
On my website ukhard house.info (without the space) on the right hand side you can see a form (username password fields and register log in buttons)
I want the register button to link to a website and i want the login button to check my phpbb database to check username and password to see if its correct, if so log them in, if not then dont do anything
I know this is a lot to ask so but could anybody do this for me? I cant really pay but i can give you a permanent text link on both my sites (sitewide) i can also give you forum dollers and maybe we can sort something else out, if your interested id really appreciate it, cheers
tony
Comments
Send a reminder in if this old fart forgets...
i wont really but that would be great if you could do that, cheers
Scripts attached as promised
The zip file contains 3 files - 2 html files and 1 php file. I tested them out on my laptop (with Apache, PHP and MySQL installed) and they work.
To test it out yourself, copy the 3 files to the same location in your server. If you need to rename or have the files in separate locations (from each other), you will need to update the html and php files according (which is very simple to do actually).
I've taken the liberty to include "forgot password" functionality for you. I guess this is quite normal nowadays.
I've thought about it and the best way to implement the register new users functionality is to have a text link to the registration page instead of having a button. If you insist of having a button for it, let me know and I'll have a go at it for you.
Logic:
1. Call login_form.html with a browser
2. Key in th username and password field and click on submit, login_form.html will call login_proc.php which will authenticate the user
3. If the user forgot his password, he'll click on the "forgot password" text link which will direct the user to login_forgot.html
3a. Key in the username and an email address to send the password to
3b. Click the submit button
3c. login_forgot.html will call login_proc.php which will retrieve the password out and send an email to the user (I've commented out the command to send the email as I was testing on my standalone laptop. Please uncomment the command yourself.)
4. If the user wants to register (new user), he'll click on the "New Registration" text link which will direct the user to a another page (please put your own page in the link)
Please change the following accordingly. At the moment, the script assumes that:
1. Your host can be accessed using "localhost"
2. Your database is called "test"
3. Your database user is "phpuser"
4. Your database user's password is "phpuser"
5. Your login table is "login_tbl"
6. Your login table has two fields named "login" and "password"
Do test it out and tell me the results... Good luck!!!
ill see if i can get it to work and let you know
It would seem that you've got the connection to the database server wrong.
These will have to be changed in the scripts...
1. Your host can be accessed using "localhost"
2. Your database is called "test"
3. Your database user is "phpuser"
4. Your database user's password is "phpuser{@}
i am going to keep your script though as i know it will be useful in the future
thanks again