// application data define("APP_DATA_FILE", "admin/application.data"); function application_start () { global $_APP; // if data file exists, load application // variables if (file_exists(APP_DATA_FILE)) { // read data file $file = fopen(APP_DATA_FILE, "r"); if ($file) { $data = fread($file, filesize(APP_DATA_FILE)); fclose($file); } // build application variables from // data file $_APP = unserialize($data); } } function getSelfz() { $server = $_SERVER['PHP_SELF']; $pieces = explode("/", $server); $pieces1 = explode(".", $pieces[1]); $pieces2 = $pieces1[0]; $_SESSION['section'] = $pieces2; } function head() { getSelfz() ?>