Foo JH wrote:
You'd see that Apache2::Request exposes more stuff, which you can (lazily) use. Unless you are looking for some backward compatibility to tradditional CGI programming, why not embrace the entire modperl library?
That sounds good to me. I'm not looking for any particular backward compatibility, and speed is an issue.
As I said in my original post, I tried to use Apache2::Request, but after creating that object, I couldn't print anything anymore. Perhaps someone could give me a hint on how to implement it?
Here's the original code again.
# BEGIN CODE BLOCK use Apache2::Const -compile => qw(OK); use CGI; sub handler { my ($r) = @_; my $cgi = CGI->new($r); $r->content_type('text/html'); if (defined $cgi->param('foo')) { print 'foo: ' . $cgi->param('foo') . "<br />\n"; } return Apache2::Const::OK; } # END CODE BLOCK
Thank you very much. Colin