F.ex. I have an archive for the Sybperl-l mailing list here. The mod_perl handler looks like this:
However, the "My::Archive" module understands things like: http://www.peppler.org/archive/sybperl-l/2003/11/7567.html by doing the following:<Location /archive> SetHandler perl-script PerlHandler My::Archive </Location>
... and yes, the mail archive is stored in a Sybase database.sub handler { my $r = shift; my $path = $r->path_info(); my $q = Apache::Request->new($r); my $dbh = getDataBaseHandle(); $path =~ s/\.html$//; my ($junk, $list, $year, $mon, $msg) = split(/\//, $path); if(!$year) { displayYears($q, $dbh, $list); } elsif(!$mon) { displayMonths($q, $dbh, $list, $year); } elsif(!$msg) { displayMsgs($q, $dbh, $list, $year, $mon); } else { displayMessage($q, $dbh, $list, $year, $mon, $msg); } }
Michael
In reply to Re: Re: Setting up mod_perl handlers
by mpeppler
in thread Setting up mod_perl handlers
by dragonchild
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |