Problems with sessions ?

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
RedRasper
Forum Commoner
Posts: 48
Joined: Thu Apr 24, 2003 6:36 am

Problems with sessions ?

Post by RedRasper »

Hello All,

Have a problem, I run a log in page, which works fine, but I have moved the new newsest version of php, and now when you click a link inside the logged in area, it seems to act like you're not logged in and takes you back to the log in area.

The code to check is :

Code: Select all

<?php

ob_start();
session_start();
if(!$_SESSION['auth'])	{
	header("login.htm");
	die();
}
ob_end_flush(); 

?>

Does anyone have any ideas?

Cheers

RedRasper
tsg
Forum Contributor
Posts: 142
Joined: Sun Jan 12, 2003 9:22 pm
Location: SE, Alabama
Contact:

Post by tsg »

I have a site with a log in area and have come to discover that some pop-up blocker programs cause this same problem.

Really don't know the answer to your question, but if you are running a pop-up blocker ... might want to see if it is that ... maybe save some hairpulling.

Tim
RedRasper
Forum Commoner
Posts: 48
Joined: Thu Apr 24, 2003 6:36 am

Post by RedRasper »

Hi!

Thank for the reply...I found what my problem was...My code is domain specific, so when I moved the domain over, and and tested just on the ip address, it wouldn't work as it wasn't the right domain.

Feel alot better now its working!

RedRasper
Post Reply