Type Conversion Bug - 08/07/2001 4:06 AM
Hi Scream,
Fix for weird language file names (at least in the logout.php routine). It might be happening elsewhere too.
In logout.php t he line
$user[loggedout] = 1;
should be
$user['loggedout'] = "1";
I have put some gettype commands in main.inc.php so I can see what is happening. When I execute logout.php from the command line (I am logged out already, no cookies), $user will have a type of "string" instead of "array" when it comes into send_header in main.inc.php. Very weird.
When this happens $user[newlanguage] is equal to "1" or "s" or whatever it grabs from memory. This causes problems with the language files because now it uses that instead of english or whatever.
$user['loggedout'] = "1"; fixes it.
I hope this helps!
Fix for weird language file names (at least in the logout.php routine). It might be happening elsewhere too.
In logout.php t he line
$user[loggedout] = 1;
should be
$user['loggedout'] = "1";
I have put some gettype commands in main.inc.php so I can see what is happening. When I execute logout.php from the command line (I am logged out already, no cookies), $user will have a type of "string" instead of "array" when it comes into send_header in main.inc.php. Very weird.
When this happens $user[newlanguage] is equal to "1" or "s" or whatever it grabs from memory. This causes problems with the language files because now it uses that instead of english or whatever.
$user['loggedout'] = "1"; fixes it.
I hope this helps!