[Phplib-users] Session/user data and default authentication
Brought to you by:
nhruby,
richardarcher
|
From: Lichte Hermann-S. <Her...@pd...> - 2002-05-16 16:10:02
|
Hello everybody! I am trying to figure out a bug in my project for at least three weeks now and I don't have a clue what it might be so this is the last chance for me to get any help. What I would like to do is the following: Have a webpage with default authentication. While authenticated as nobody collect data from the nobody-user and store it in session variables (works fine!). Then there is a page that forces login (using login_if(1)). After the nobody-user has successfully logged on I'd like to transfer the values of the session variables to his user variables, so that they won't be lost after he logs out. The problem, however, is: After logging on, the session variables are corrupted. They have values other than the ones gathered before. And I don't know why. While searching for the bug, I have removed any code from my scripts that refers to user variables. I am trying to see whether the session variables keep their values before and after logging on - but the program behaves strangely: First step: Suppose there's a variable called A. While being nobody, this variable is set to 1. After logging on its value is <undefined>. Now while logged on this variable will be set again to 1. Second step: Restart the browser. While being nobody, the variable A is set to 3. After logging on its value is 1. Now while logged on this variable will be set again to 3. Second step: Restart the browser. While being nobody, the variable A is set to 12. After logging on its value is 3. etc. How can that be? I am not using any register() methods from user-classes. It's just the session-class I am interacting with. I can't figure out why this systems behaves this way. I thought the session wouldn't change after logging on. Can something like the above be done using PHPLIB and - if it can be done - what could cause such a strange behaviour? Many thanks for any hints (even those that don't point into the right direction). Hermann-Simon Lichte |