lol wow, thanks guys I don't know, the slight version difference seems the first thing you'd try looking at. I figured out how sessions work from the PHP website though, and they have stuff for 5.0.
Basically, there are two scripts: The login script itself, and a check_login script that seems to failing to pass the session data along.
Login is fairly straight forward, gather a username and password, then start a PHP session with session_start(), use PEAR::DB to connect to a SQL database, and check that the password supplied is the one for that username in the database. If it is, it sets $_SESSION['username'] and $_SESSION['password'] and then redirects the user to the home page.
This is where I get problems. The check_login script is contained in the header of the home page, and it has a check to let the user know something's wrong when you are "logged in", but there's no session data, or it doesn't match the database info. I keep losing ALL session array data when check_login checks the user's credentials while loading the home page.
The check_login script initiates (or continues) a session, then uses PEAR::DB to connect to a SQL database, and grab the encrypted password that corelates to the current $_SESSION['username'], if a session has already been established. Assuming the db_pass matches the $_SESSION['password'], it sets the $logged_in variable to 1, otherwise it's set to 0.
Is there another way to set session variables for the new PHP version besides:
session_start();
$_SESSION['name']="data";
Anybody have any idea what changed so radically between 4.3.10 and 4.3.11?]]
Also, here's the check_login script, if anyone's interested. I call it from db_connect.php, which actually has all the database and PEAR stuff in it. Hey, it works on 5 or 6 sites I have on 4.3.10 lol maybe you can use it.
check_login.php
db_connect.php