Helpful Information
 
 
Category: Perl Programming
What exactly is mod_perl?

Im a Perl newbie, and what exactly is
mod_perl?

I have a cgi-bin directory for cgi scripts,
does this have anything to do with
mod_perl??

thanks

ToolJob

Simply put, mod_perl is a perl interpreter which is built into the Apache web server. There are more precise definitions, but this one is the easiest to understand. The process of writing perl scripts is almost the same, however there are a few things you need to watch out for. As a example, all file handles need to be closed beforethe script is over. This differs from the standard Perl style.

Useful link: http://perl.apache.org/ .

HTH. http://www.devshed.com/Talk/Forums/wink.gif

Hi ToolJob,

mod_perl module makes your Perl scripts run fast, by turning them into compiled exectables inside Apache server. If you have mod_perl on your server, do not protest. It is the fine thing to have.

Just observe the following rules:
1) declare variables like this:

my $somevar;
$somevar="a value";

2)never call 2 variables the same, even if they are in different scripts.

If you do it, you will be OK, if not, then you will see the frightful occurrence of the so-called "sticky variables".

A cgi-bin folder you may have also without mod_perl. It is just a place to put your scripts in.

Alexey










privacy (GDPR)