Hi,
I finished a project on my laptop and now I am trying to take it online. I created the project using php 4.3.6 on my laptop. The server is running php 4.3.2.
My problem is this, in the code bellow, when the user first comes to the page a user class is created for them and stored in a session variable. As they proceed through the site, if there is a class already defined for them, it unserializes it, and uses it. The problem is in the else branch, it does not unserialize properly or something. All 3 echo statments don't work, and the third says the obvious, i am trying to access a member function that does not exist.
This works perfectly on my laptop, but not on the server. I have tried deleting everything off the server and re-uploading also. If you want to see the phpinfo of the server go to www.stockboulevard.com
If you know what is going on please help
Thanks,
papayiya
if(!empty($_SESSION['user'])){
$user = unserialize($_SESSION['user']);
echo "1cont) ".$user;
echo "2cont) ".$user->db;
echo "3cont) ".$user->db->quote("3214");
}
else {
session_defaults();
$db = db_connect();
$user = new User($db);
$_SESSION['user'] = serialize($user);
echo "1) ".$user;
echo "2) ".$user->db;
echo "3) ".$user->db->quote("3214");
}