Location: PHPKode > scripts > SessionManager > sample.php
<?php
include("SessionManager.php");

// Constructor call: $session = new SessionManager("path_for_session", client_ip, expiration_time)
//
//		path_for_session: local directory where the session files will be stored
//		client_ip: client ip used to handle session, you can use $REMOTE_ADDR.
//		expiration_time: the time in minutes that the session is going to be active. 
$sessao = new SessionManager("./",getenv("REMOTE_ADDR"),100);

// Create and start the session engine
$sessao->createSession();

// Store some variables in the session
$sessao->registerSessionVar("exp1","Hello");
$sessao->registerSessionVar("exp2","World!");
$sessao->registerSessionVar("exp3","Man");

// Load and print stored variables
print("exp1 = " . $sessao->getSessionVar("exp1") . "<br>");
print("exp2 = " . $sessao->getSessionVar("exp2") . "<br>");
print("exp3 = " . $sessao->getSessionVar("exp3") . "<br>");
?>
Return current item: SessionManager