Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re^3: Getting started with mod_perl

by clinton (Priest)
on Jul 14, 2008 at 10:39 UTC ( #697432=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Getting started with mod_perl
in thread Getting started with mod_perl

So you have to put every single such file into the configuration.

This is not necessarily the case. I tend to have a single entry point to my mod_perl application (a dispatcher), which handles everything below / except for (eg) paths to static content:

<Location ~ "^/(?!img|stylesheets|scripts|robots.txt|favicon.i +co|error).*" > SetHandler perl-script PerlResponseHandler My::Dispatcher </Location>

and that single handler parses the request, then hands it off to the relevant handler in my code. Once that handler has processed the request, it passes back the relevant data, template name etc, and my dispatcher handles the template processing and returns the correct response.

This allows you to do pretty much everything in Perl, without having to worry too much about apache.


Comment on Re^3: Getting started with mod_perl
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://697432]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (8)
As of 2014-12-21 10:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (104 votes), past polls