Jump to content

[SOLVED] password and sessions


dahwan

Recommended Posts

hey again... [url=http://www.dahwan.com]www.dahwan.com[/url]
i am trying to make all the pages in my directory unavaliable exept index.php
i am trying to use sessions to remember if the person wrote the right password in index.php, and if he did, he gains acces to all the pages in the directory like gallery.php and news.php
get what i mean?
my only problem is; i dont know anything about sessions!

can you help me? thanks!

dahwan
Link to comment
https://forums.phpfreaks.com/topic/31837-solved-password-and-sessions/
Share on other sites

it is possible. just make the cookie expire when he closes the browser

first when he enters the password, i'd use javascript to make him store the cookie.

then when he request '/gallery.php', use php to check if he has the correct cookie

http://au2.php.net/manual/en/function.http-parse-cookie.php
Not really. Just like most other forums the more you post, the more respectable and trusted you'll become.

Obviously, if you just spam crap then you'll be banned and not become that respectable and trusted employee of the month that you've always dreamed of... sigh.

Ahem, sorry, daydreaming...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.