You can start a session with the session_start() function.
You can access the session's ID with the session_id() function.
You set an element in the superglobal $_SESSION array.
The session_destroy() function removes all traces of a session for future requests.
You can unset session elements by unsetting all elements of the $_SESSION array, like so:
$_SESSION = array();
If cookies are not available, the SID constant contains a name/value pair that can be incorporated in a query string. This will pass the session ID from script request to script request.