You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Devin Murphy <mu...@yahoo.com> on 2005/04/19 18:30:42 UTC

Implementing abstract URI with mod_perl?

I'm trying to implement abstract URL / URI calls.

For my htdocs directory (and .html files), the
MultiViews option works fine.  For example,
http://localhost/address will resolve to its
respective html file.

No such luck when I'm trying to get Apache to resolve
.pl files.  For example, http://localhost/perl/counter
gives me a 404 error.  (The full path,
http://localhost/perl/counter.pl, works right)

The idea is to hide the .pl extension from average
users / links / &c.

I've set up a simple Location tag:

<Location /perl>
   SetHandler perl-script
   PerlHandler ModPerl::Registry
   Options +ExecCGI
   PerlSendHeader On
</Location>

And it seems like MultiViews option causes problems
with the scripts (it denies access / 403 error).

Also no luck setting up a typemap / .var file.

Any hints?

Thanks,

Devin Murphy


		
__________________________________ 
Do you Yahoo!? 
Read only the mail you want - Yahoo! Mail SpamGuard. 
http://promotions.yahoo.com/new_mail 

Re: Implementing abstract URI with mod_perl?

Posted by Slava Bizyayev <sb...@outlook.net>.
On Tue, 2005-04-19 at 11:30, Devin Murphy wrote:
> I'm trying to implement abstract URL / URI calls.
> 
> For my htdocs directory (and .html files), the
> MultiViews option works fine.  For example,
> http://localhost/address will resolve to its
> respective html file.
> 
> No such luck when I'm trying to get Apache to resolve
> .pl files.  For example, http://localhost/perl/counter
> gives me a 404 error.  (The full path,
> http://localhost/perl/counter.pl, works right)
> 
> The idea is to hide the .pl extension from average
> users / links / &c.
> 
> I've set up a simple Location tag:
> 
> <Location /perl>
>    SetHandler perl-script
>    PerlHandler ModPerl::Registry
>    Options +ExecCGI
>    PerlSendHeader On
> </Location>
> 
> And it seems like MultiViews option causes problems
> with the scripts (it denies access / 403 error).
> 
> Also no luck setting up a typemap / .var file.
> 
> Any hints?

How about fine tuning of mod_rewrite or to write a simple
PerlTransHandler?

Thanks,
Slava