Register session variables : Session Variables Register « Cookie Session « PHP






Register session variables

<?php
  $sessionold = session_name ( 'A' ) ;
  $sessionnew = session_name ( 'B' ) ;
  $sessionlatest = session_name ( 'C') ;

  session_register ( 'D' ) ;

  echo "The old session name was $sessionold.", "\n" ;
  echo "The new session name is $sessionnew! ", "\n" ;
  echo "The latest session name is $sessionlatest!! " ;
?>
           
       








Related examples in the same category

1.Registering an Array Variable with a Session