user authentication

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
aneuryzma
Forum Contributor
Posts: 106
Joined: Sat May 17, 2008 7:03 am

user authentication

Post by aneuryzma »

hi,

could you suggest me some tutorial/book about how to implement:

the users authentication (login / logout) and how to store profiles... etc ?

thanks
ldougherty
Forum Contributor
Posts: 103
Joined: Sun May 03, 2009 11:39 am

Re: user authentication

Post by ldougherty »

Hello,

The most popular way to handle logging in and out via PHP is with Sessions. The following tutorial from w3schools should get you pointed in the right direction.

http://www.w3schools.com/PHP/php_sessions.asp

As for storing profiles, this depends on what you want to store. For example I've created a login system on a gallery that just uses sessions to determine if you are logged in or not and the username/password used to log in references the mySQL backend where user profile information is stored.

If you want to store login information so that the user is recognized the next time they visit your site you'll want to look into Cookies

http://www.w3schools.com/PHP/php_cookies.asp

Hope this helps out.
aneuryzma
Forum Contributor
Posts: 106
Joined: Sat May 17, 2008 7:03 am

Re: user authentication

Post by aneuryzma »

thanks for suggestion!

I've found also this one.. if can help somebody else..

http://www.phpro.org/tutorials/Basic-Lo ... MySQL.html
Post Reply