> > I'm having problems with the PerlTransHandler handler. I would like
> > to only translate some requests, but keep Aliases working. However, I
> > just can't get that done. If I use a simple 'return DECLINED;', all
> > my cgi scripts and aliases directories return 'Not found'. I know the
> > handler is executed, and if I remove it from httpd.conf, everything
> > works fine. What am I doing wrong? Should a simple 'return
> > DECLINED;' run default handlers, or am I missing something? Thanks in
> > advance.
>
> return DECLINED; should work fine. can you post a tiny example config and
> handler? Apache::ShowRequest (part of the Apache::Module package on CPAN)
> can also help debug this sort of problem.
A little more information. Originally, I was trying this on Redhat
5.2, now just tried it on 6.2 with stock apache and stock mod_perl.
Same result.
I've added the line marked by + to the default httpd.conf:
--
<IfModule mod_perl.c>
+ PerlTransHandler handler
Alias /perl/ /home/httpd/perl/
<Location /perl>
SetHandler perl-script
--
This is my handler.pm:
--
#!/usr/bin/perl
package handler;
use Apache;
sub handler {
return DECLINED;
}
1;
--
With this config, no requests work. Not even a request to the root of
the server, which has the default apache test page installed. If I
remove the PerlTransHandler line from the config and restart apache,
everything works.
There are the stats from the box I've tried it on:
--
[modemch@rabox4 modemch]$ rpm -qa | grep 'apache\|mod_perl'
apache-1.3.12-2
mod_perl-1.21-10
[modemch@rabox4 modemch]$ uname -a
Linux rabox4.eventsdigital.com 2.2.14-5.0 #1 Tue Mar 7 20:53:41 EST 2000 i586 unknown
[modemch@rabox4 modemch]$ cat /etc/issue
Red Hat Linux release 6.2 (Zoot)
Kernel 2.2.14-5.0 on an i586
[modemch@rabox4 modemch]$
--
I really really need to get to the bottom of this. Thanks for all your help.