What if you use something like SourceForge. If you try to access a page the requires you to be logged in when it redirects you to the login page it includes in the URL the page that the user tried to access (ie login.php?redirect=page3.php) Then when the user successfully logs in they redirect to the page. If it's not set the go to page1.php.
On Wed, 2003-12-17 at 14:04, Hunter, Jess wrote: > I have created a simple login/authentication script to help protect some of > my PHP pages. Here is where I am running into a little trouble in > understanding. > > Let's Say I have the following pages protected > > Page1.php > Page2.php > Page3.php > > If the user is not logged in, the "inc." file will send them to login.php, > upon proper log in, it will shoot the person over to Page1.php. > > But let's say the user tries to go to Page3.php, the script will send them > to the login.php page, which will then send them to Page1.php. How could I > go about making it so if the person is trying to goto page3.php, that after > proper login, they will be directed to page3.php and not page1.php? > > Thanks in advance for any assistance > > Jess > > --- > Outgoing mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.550 / Virus Database: 342 - Release Date: 12/9/03 > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php -- "I have a photographic memory. I just forgot the film" --Unknown ============================= Ryan Thompson [EMAIL PROTECTED] http://osgw.sourceforge.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php