Re: Securing a File with php

From: Date: Tue, 28 Nov 2000 18:38:06 +0000
Subject: Re: Securing a File with php
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-27654@lists.php.net to get a copy of this message
I would do this: On successful log in, create a session variable for the user like "login=1" On all the pages that you want secured....put an "if login = 1" at the top of the php page. This way if someone tries to access that page they will not have a value for login and will get bumped out (or wherever you want to put them from your "else" statement.) Hope this helps > Hello, > I have a secure login which works fine. But I have a > document that when you do a direct link to it, people > can view it. Is there a way of securing that document > without using a .htaccess file with php. I've tried > to move it outside of the /home/html path but could > not get it to work. > Thanks for any help. > --Mike > > __________________________________________________ > Do You Yahoo!? > Yahoo! Shopping - Thousands of Stores. Millions of Products. > http://shopping.yahoo.com/

« previous php.general (#27654) next »