Session 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
kickinhard007
Forum Newbie
Posts: 2
Joined: Wed Oct 23, 2002 3:32 am

Session Authentication

Post by kickinhard007 »

Howdy,

I'm a bit oif a newbie when it comes to PHP (HTML and MySQL are more my thing) and i'm looking for some info based the tutorial by "enygma" that covered the use of session ID's.

Basically I need a basic username and password form on my front page that sets the values $user and $pass, and also sets $logged_in to "1".

Then all I want to do is be able to put a chuck of code on each page that I want to secure, that checks to see if the user if logged in correctly so the page can be displayed....if the user isn't, then a simple echo "Login!"; statement will suffice!

Can anyone help? :-)

I'll resort to bribery if I have to!

Kickinhard007
browsing@rocketdave.co.uk
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post by twigletmac »

Try a search on 'session AND login' or somat like that - the code for what you want is definitely in here somewhere :) .

If you've got a bit of code you've already started on we're happy to help with it, we're much more a 'helping you with your own code' kinda place than a 'writing it for you' one...

Mac
kickinhard007
Forum Newbie
Posts: 2
Joined: Wed Oct 23, 2002 3:32 am

Post by kickinhard007 »

cheers! sorry if my request was a tad cheeky :-)

Kickinhard007
Post Reply