justsimple has asked for the wisdom of the Perl Monks concerning the following question:

I have just installed mod_perl. Everything is good, exept one thing. It's my httpd.conf part of mod_perl:
Alias /page/ /home/me/page/   
PerlModule Apache::Registry
<Location /page/>
    SetHandler perl-script
    PerlHandler Apache::Registry
    Options ExecCGI
    PerlSendHeader On
    allow from all
</Location>
All my perl scripts in this dir WORK, but I can't access other files. For example I can't access http://localhost/page/foto.jpg. foto jpg has permissions rwxrwxrwx. I can't figure why I can access perl scripts and can't access other files. What should I do?

Replies are listed 'Best First'.
Re: Can't figure with mod_perl
by Fletch (Bishop) on Jun 27, 2004 at 13:50 UTC

    This is because you've told mod_perl to pass everything in the directory this URI maps to through Apache::Registry (including JPGs). A better solution might be to use a <Files> section to set the handler for non-jpg files, or to place your JPGs in a different directory not under the Apache::Registry enabled one.

Re: Can't figure with mod_perl
by thor (Priest) on Jun 27, 2004 at 13:51 UTC
    What are the permissions on the directory where the files you can't access live? Is it readable by your apache process?

    thor