We are going to repeat the example of testing native PHP session handling, with a twist. The SessionManager
will be used for handling the session.
1. Create a new PHP script in your text editor with the following code:
<?php //Session started by requiring the script require('session.php'); //Generate a random number $random_number = rand(); //Put the number into session $_SESSION['random_number'] = $random_number; ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> <link rel="stylesheet" href="style.css" /> <title>Using the SessionManager...Page 1</title> </head> <body> <div id="contentarea"> <div id="innercontentarea"> <h2>Using the SessionManager...