- or download this
# create a new session
my $session = CGI::Session->new() or die CGI::Session->errstr;
...
print "<a href='logout.cgi'>logout </a></br>";
# check option
print "<a href='check.cgi'>check page</a>"
- or download this
# cgi page
my $cgi = CGI->new;
...
print $session->is_expired;
}
print $cgi->end_html();
- or download this
# Delete the session for good:
my $session = CGI::Session->load() or die CGI::Session->errstr;
$session->delete();
$session->flush();
print $session->header(-location=>'http://localhost');