On Tue, Aug 19, 2008 at 17:58, Peter Milanese <[EMAIL PROTECTED]> wrote:

> Not so sure where this break is, or even if my config is done correctly. It
> seems to be pretty basic perl, of which I'm pretty veteran. Does anyone know
> what's going on ? Here's the code:

One thing I found out when implementing configs in perl is that you
have to declare all the variables you use as local, using "my"
statements. This because any global variable perl will try to match
against an apache directive with the same name.

Your problem is that you are not declaring your variables as local, so
your first statement:
"$s = Apache2::ServerUtil->server;"
results in perl looking for a directive "s" of type
"Apache2::ServerRec", which of course fails.

So write your perl sections as if you had "use strict;", and declare
all your variables local using "my", unless you want to directly pass
something to apache.
So use:
my $s = Apache2::ServerUtil->server;

You need to do this each time you introduce a local variable, eg:
 my   $hostname=hostname();
otherwise you will be setting the Apache directive to your hostname.

HTH,

Krist

-- 
[EMAIL PROTECTED]
[EMAIL PROTECTED]
Bremgarten b. Bern, Switzerland
--
A: It reverses the normal flow of conversation.
Q: What's wrong with top-posting?
A: Top-posting.
Q: What's the biggest scourge on plain text email discussions?

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
   "   from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to