Hi,
I have some trouble getting session management to work. I'm using
Apache Session 1.03, Embperl 1.3b4 with mod_perl on Apache 1.3.12,
here what I put in the httpd.conf:
SetEnv EMBPERL_DEBUG 2375713
SetEnv EMBPERL_VIRTLOG /embperl/log
PerlSetEnv EMBPERL_COOKIE_DOMAIN "www.macnews.de"
PerlSetEnv EMBPERL_COOKIE_NAME "SessionID"
PerlSetEnv EMBPERL_COOKIE_PATH "/umfrage/dialog"
PerlSetEnv EMBPERL_SESSION_CLASSES "DBIStore SysVSemaphoreLocker"
PerlSetEnv EMBPERL_SESSION_ARGS "DataSource=dbi:mysql:session UserName=apache Password=extremlysecret"
PerlModule Apache::Session
PerlModule HTML::Embperl
<Location /dialog/umfrage>
SetHandler perl-script
PerlHandler HTML::Embperl
Options ExecCGI
</Location>
However I never get a cookie from Embperl! I also tried with FileStore
instead of DBIStore. Maybe I didn't understand the documentation
right, but normally this small script should work:
<html>
<head>
<title>Test</title>
</head>
<body>
Hmm:<br>
[$ if defined($udat{sometime}) $]
<b>First started: [+ $udat{sometime} +]</b><br>
[$ else $]
[- $udat{sometime} = localtime; -]
<b>Setting time to:</b> [+ $udat{sometime} +]
[$ endif $]
</body>
</html>
Everytime I reload this page it prints the server time... What am I
doing wrong? ;-)
Please let me know if you need more information!
Ciao,
Eric
I have some trouble getting session management to work. I'm using
Apache Session 1.03, Embperl 1.3b4 with mod_perl on Apache 1.3.12,
here what I put in the httpd.conf:
SetEnv EMBPERL_DEBUG 2375713
SetEnv EMBPERL_VIRTLOG /embperl/log
PerlSetEnv EMBPERL_COOKIE_DOMAIN "www.macnews.de"
PerlSetEnv EMBPERL_COOKIE_NAME "SessionID"
PerlSetEnv EMBPERL_COOKIE_PATH "/umfrage/dialog"
PerlSetEnv EMBPERL_SESSION_CLASSES "DBIStore SysVSemaphoreLocker"
PerlSetEnv EMBPERL_SESSION_ARGS "DataSource=dbi:mysql:session UserName=apache Password=extremlysecret"
PerlModule Apache::Session
PerlModule HTML::Embperl
<Location /dialog/umfrage>
SetHandler perl-script
PerlHandler HTML::Embperl
Options ExecCGI
</Location>
However I never get a cookie from Embperl! I also tried with FileStore
instead of DBIStore. Maybe I didn't understand the documentation
right, but normally this small script should work:
<html>
<head>
<title>Test</title>
</head>
<body>
Hmm:<br>
[$ if defined($udat{sometime}) $]
<b>First started: [+ $udat{sometime} +]</b><br>
[$ else $]
[- $udat{sometime} = localtime; -]
<b>Setting time to:</b> [+ $udat{sometime} +]
[$ endif $]
</body>
</html>
Everytime I reload this page it prints the server time... What am I
doing wrong? ;-)
Please let me know if you need more information!
Ciao,
Eric