perl-asp mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joshua Chamas <>
Subject Re: Apache::ASP error re: subroutines
Date Tue, 22 May 2001 21:49:21 GMT
Andrew Koebrick wrote:
> Howdy,
> I am attempting to move a few subroutines from my Apache::ASP pages into a central module,
but get the error:
> Undefined subroutine &Apache::ASP::Demo::date_swap called at (eval 6) line 67. ,
/usr/lib/perl5/site_perl/5.6.0/Apache/ line 1506

PerlSetVar GlobalPackage is set to Apache::ASP::Demo I bet, and you called
the sub date_swap() which was not defined there.

> Is there something funky in the Apache::ASP environment regarding how/where modules are
handled?  The functions work when in the page, so I dont think there is an internal error
there.  I am calling the module with a basic "use ASK" ( is the module name).  The module
has appropriate ownership/rights.

If you sub is in, then you can reference it like:


or you could define the sub in the global.asa, which takes
on the package name from GlobalPackage, so the sub will be 
in the same package that all your scripts are compiled into.

> I am especially curious why it is looking for dateswap under Apache::Demo::XXX

This is the package that your ASP scripts & includes are compiled into.

Also there is a new mailing list for Apache::ASP at,
but I have been slow to update the docs at the ASP web site & README.


Joshua Chamas			        Chamas Enterprises Inc.
NodeWorks >> free web link monitoring	Huntington Beach, CA  USA                1-714-625-4051

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message