--------------------------------------------------------------------------- 18 July 1998 Jeffrey Baker --------------------------------------------------------------------------- DESCRIPTION ----------- This is Apache::Session 0.14. These modules are used to keep persistent user data across http requests. Apache::Session was designed for use with Apache and mod_perl. Four storage systems are defined: DBI-compliant database, Win32 shared memory, IPC shared memory, and flat files. Apache::Session is Copyright(c) 1998 Jeffrey William Baker . Distribute under the Artistic License. PREREQUISITES ------------- Build and install Perl (pref. 5.004_04), Apache (pref. 1.3.0) and mod_perl (pref. 1.14). To use Apache::Session at all, you must have the MD5 module, available on CPAN (http://www.perl.com/CPAN). Apache::Session::DBI needs DBI and at least one DBD, plus FreezeThaw, available on CPAN. Apache::Session::Win32 requires that you be using a Win32 operating system (e.g. Windows NT). Apache::Session::IPC requires the IPC::Shareable module and a SysV IPC compliant operating system. Apache::Session::File requires the Storable module and a writeable file- system. INSTALLATION ------------ tar -xvzf Apache-Session-0.14.tar.gz cd Apache-Session-0.14 perl Makefile.PL make make test make install Substitute "nmake" for "make" above if you are using Windows. Consult the pod for the storage mechanism that you plan on using. EXAMPLE ------- use Apache; use Apache::Constants; use Apache::Session::Win32; my $r = Apache->request(); $r->content_type("text/html"); $r->status(200); $r->send_http_header; my $session_id = $r->path_info(); # storing session id in the URL $session_id =~ s/^\///; my $session = Apache::Session::Win32->open( $session_id, { autocommit => 0, lifetime => 3600 } ) || Apache::Session::Win32->new( { autocommit => 0, lifetime => 3600 } ); $session_id = $session->{'_ID'}; $session->{'username'} = {'John Doe'}; $session->store(); print "Your name is ".$session->{'username'}; AUTHORS ------- Jeffrey Baker is the author of Apache::Session. Randy Harmon created storage independence through subclassing, with useful comments, suggestions, and source code from: Bavo De Ridder Jules Bean Lincoln Stein Doug MacEachern wrote mod_perl. Larry Wall wrote perl. This README format is shamelessly stolen from Edmund Mergl FURTHER INFORMATION: -------------------- Apache by Apache Group comp.infosystems.www.servers.unix http://www.apache.org/ mod_perl by Doug MacEachern modperl@apache.org http://perl.apache.org/