medaswho Posted March 10, 2009 Share Posted March 10, 2009 Warning: Unknown: Your script possibly relies on a session side-effect which existed until PHP 4.2.3. Please be advised that the session extension does not consider global variables as a source of data, unless register_globals is enabled. You can disable this functionality and this warning by setting session.bug_compat_42 or session.bug_compat_warn to off, respectively. in Unknown on line 0 what is happening at this moment is trying to load some values into session variables. i googled this warning and the most consistant answer is that session doesn't like null values but the values are not null. any help? Quote Link to comment https://forums.phpfreaks.com/topic/148702-any-one-ever-seen-this-warning-before/ Share on other sites More sharing options...
ngreenwood6 Posted March 10, 2009 Share Posted March 10, 2009 Can you show us how you are starting the session as well as how you are setting the values? Quote Link to comment https://forums.phpfreaks.com/topic/148702-any-one-ever-seen-this-warning-before/#findComment-780823 Share on other sites More sharing options...
PFMaBiSmAd Posted March 10, 2009 Share Posted March 10, 2009 The error is a result of the way that register_globals is implemented and that even with register_globals disabled, the register_globals code is still being executed except for the final step of actually cross-populating same name post/get/cookie/session and program variables. The error is triggered when you have a session variable and a program variable by the same name and one of them is being created with a null value. You can set the two bits the error mentions to off to prevent the display of the error or you can use unique names for session and program variables (or wait for php6 where most of the register_globals code, except for the request variable, has finally been removed from php.) Quote Link to comment https://forums.phpfreaks.com/topic/148702-any-one-ever-seen-this-warning-before/#findComment-780908 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.