Hello all,
After a year away from Embperl (and the web in general), I'm trying to
get some old code from Embperl 1.3 up and running again. The code
assumes optRedirectStdout is true and makes lots of calls to print
statements (it's in a module).
However, while 'print OUT "hello"' works fine, when I run:
[- print "hello"; -]
I get:
Error in Perl code: Can't locate object method "PRINT" via package
"Apache::RequestRec" (perhaps you forgot to load
"Apache::RequestRec"?) at /usr/local/apache2/quiz/test.epl line 4.
The code:
optRedirectStdout is [+ $optRedirectStdout +]
tells me that it is "1", so it is not a problem with setting
optRedirectStdout.
I could live with changing all calls to 'print OUT' but when I attempt
this from within a module that is used by the Embperl page I get:
print() on unopened filehandle Quiz::Presenter::OUT
despite what I understand to be aliasing code in
Embperl::Out. Further, if I fully qualify the filehandle I still get:
print() on unopened filehandle Embperl::OUT
Does anybody know what's going on?
Regards,
Lincoln
School of Physics, University of Melbourne; on sabbatical at
Physics Department / n-laag G1.02 Work: (31 40) 247 4793
Technische Universiteit / Eindhoven Fax: (31 40) 245 6050
PO Box 513, 5600MB Eindhoven Mobl: +31 625 575746
The Netherlands
--
I am running Embperl/2.0b8 Apache/2.0.40 (Unix) mod_perl/1.99_05-dev
Perl/v5.6.1 on a just-installed redhat 7.2 i386 system. My httpd.conf
has:
LoadModule perl_module modules/mod_perl.so
LoadModule embperl_module
/usr/lib/perl5/site_perl/5.6.1/i386-linux/auto/Embperl/Embperl.so
PerlTaintCheck On
PerlWarn On
PerlModule Apache2
PerlModule Embperl
PerlInitHandler Apache::StatINC
Perlrequire /usr/local/apache2/conf/startup.pl
Perlrequire /usr/local/apache2/quiz/lib/quiz.pm
AddType text/html .epl
AddHandler cgi-script .cgi
Alias /quiz/ "/usr/local/apache2/quiz/"
<Location /quiz>
EMBPERL_APPNAME embperl_quiz
EMBPERL_OBJECT_BASE base.epl
EMBPERL_URIMATCH \.htm.?|\.epl$
EMBPERL_ESCMODE 0
EMBPERL_OPTIONS 16384
SetHandler perl-script
PerlHandler Embperl::Object
Options ExecCGI
</Location>
---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org
|