Jump to content

[SOLVED] SESSION_REGISTER()


chaiwei

Recommended Posts

deprecated means It's still possible to use it but that you can run into problems since it wont get updated anymore.

 

use that instead ^^

session_start();
$_SESSION["variable_something"] = 'Yay! i'm into a session var!!';

 

edit : thanks DarkWater for session_start() I forgot :P

session_register() is indeed deprecated.  That means that it is highly discouraged to use it at all, and it could be potentially removed.  You should just use the $_SESSION superglobal for all your session needs. :D

 

<?php
session_start();
$_SESSION['name'] = "DarkWater";
?>

session_register(), session_is_registered() and session_unregister() are dependent on register_globals. Register_globals were turned off starting in php4.2 in the year 2002. No new code should have been written after that point in time that used these functions. These functions have been removed in php6. Any code using them will stop working under php6 and must be changed to use the $_SESSION array variables.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.