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

Re: Perl, PHP mod_perl

by Errto (Vicar)
on Oct 28, 2009 at 15:19 UTC ( #803699=note: print w/ replies, xml ) Need Help??


in reply to Perl, PHP mod_perl

Well, it won't be exactly the same architecture obviuosly. But it can be similar. You'll have to install and configure mod_perl. The feature you'll want to use is ModPerl::Registry which allows you to run your Perl program as if it were a CGI program. You'll need to make a few changes in the script itself:

  • Have some other logic for passing the command line options. If they should be dynamic, use a query string or something. If they should be static, have them come from config variables in your Apache config
  • You'll have to generate the proper response headers for "CGI" output. Now you're presumably doing it in the PHP script, so you have to do that in Perl instead.
  • Likewise with whatever cosmetic changes you're doing.


Comment on Re: Perl, PHP mod_perl

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (20)
As of 2015-07-06 18:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (80 votes), past polls