hostfreak Posted September 7, 2007 Share Posted September 7, 2007 I see a good bit of people using session_register(). I personally always use $_SESSION[] array... from my understanding, session_register() relies on register_globals. So really, in php PHP 6.0.0 it will be depreciated (seeing how register_globals will be removed). I don't even understand why anyone would use it in the first place, over $_SESSION[] Quote Link to comment https://forums.phpfreaks.com/topic/68369-solved-sessions-session_register-vs-_session/ Share on other sites More sharing options...
wildteen88 Posted September 7, 2007 Share Posted September 7, 2007 before in order to create a session in the register_global's era you'd have to use session_register to register a session variable, as $_SESSION didn't even exist back then. There were no pre-defined variables as there is now to define a session without calling session_register. Now PHP has moved on and register_globals is now depreciated and so no need to use session_register. Some people may still use session_register because of old habits back in the register_global's era, or has read up on an old tutorial for using PHP sessions. Quote Link to comment https://forums.phpfreaks.com/topic/68369-solved-sessions-session_register-vs-_session/#findComment-343826 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.