Posted On: May 13, 2020
In PHP 5.3 or below we can register a variable session_register() function.It is deprecated now and we can set directly a value in $_SESSION Global.
<?php // Starting session session_start(); // Use of session_register() is deprecated $username = "PhpScots"; session_register("username"); // Use of $_SESSION is preferred $_SESSION["username"] = "PhpScots"; ?>
Never Miss an Articles from us.
In PHP == is equal operator and returns TRUE if $a is equal to $b after type juggling and === is Identical operator and return TRUE if $a is equal to $b, and they are of the same data type...