Return to Snippet

Revision: 32806
at October 2, 2010 08:46 by sb_01


Initial Code
function startSession() {
    session_name($this->session_name);
	$ok = @session_start();
	if(!$ok){
	   session_regenerate_id(true); // replace the Session ID
	   session_start(); // restart the session (since previous start failed)
	}
}

Initial URL


Initial Description


Initial Title
Start a secure session

Initial Tags
php

Initial Language
PHP