I've read about securing sessions awhile ago but I don't know if I am using it right. All I know is that it replaces the current ID with a new one.
So for example:
$user = 'popo';
$_SESSION['user']= $user ;
session_regenerate_id(true);
is that the right way of using session_regenerate_id?