?
Solved

mod_perl problem

Posted on 2003-03-27
6
Medium Priority
?
163 Views
Last Modified: 2010-03-05
i am trying to setup mod perl on my devlopment server...

i tried following to configuration on my linux box

httpd2 with mod_perl_1.99(latest)

apache1.3.27 with mod_perl_1

and when i run my test script(test.pl) ,the script simply displays content of file (as text file).

any help ?

Lk
0
Comment
Question by:lokeshv
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 3

Expert Comment

by:tosch
ID: 8219874
you have to configure your server to use mod_perl ;).

the lines for httpd.conf look somewhat like this:

LoadModule perl_module /usr/lib/apache/libperl.so
AddModule mod_perl.c

<Location /perl>
   SetHandler perl-script
   PerlHandler Apache::Registry
   PerlSendHeader On
</Location>

0
 
LVL 4

Author Comment

by:lokeshv
ID: 8220311
this is for version 2 or 1 ?
0
 
LVL 3

Expert Comment

by:tosch
ID: 8223576
for both, i think.

my web server (where this piece of httpd.conf is from) is still running apache 1.3 (i'll update it soon - i don't expect to have to change these lines ;).
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 4

Author Comment

by:lokeshv
ID: 8227184
when i add line LoadModule i get warning msg perl module is already loaded...

and the result is still same ...dispalyes the code..


0
 
LVL 3

Accepted Solution

by:
tosch earned 800 total points
ID: 8230023
ok, then the LoadModule line is already in yout config.


<VirtualHost www.mydomain.com>

  [...]

  Alias /perl/ /web/www.mydomain.com/perl/
  <Location /perl/>
     SetHandler perl-script
     PerlHandler Apache::Registry
     PerlSendHeader On
  </Location>

  [...]

</VirtualHost>

this causes scripts in the directory /web/www.mydomain.com/perl/ to be accessible at http://www.mydomain.com/perl/[scriptname.pl]

or if you don't use VirtualHosts just put it in the scope of the default web site.
0
 
LVL 20

Expert Comment

by:jmcg
ID: 9707593
Nothing has happened on this question in over 7 months. It's time for cleanup!

My recommendation, which I will post in the Cleanup topic area, is to
accept answer by tosch.

Please post any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

jmcg
EE Cleanup Volunteer
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Email validation in proper way is  very important validation required in any web pages. This code is self explainable except that Regular Expression which I used for pattern matching. I originally published as a thread on my website : http://www…
I have been pestered over the years to produce and distribute regular data extracts, and often the request have explicitly requested the data be emailed as an Excel attachement; specifically Excel, as it appears: CSV files confuse (no Red or Green h…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Six Sigma Control Plans
Suggested Courses

800 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question