On Tue, 6 Feb 2007, Jonathan Vanasco wrote:

I'm going to talk in context of CGI::Apache2::Ajax, as I haven't had time to look at the rest.

Personally, I would like to see something in terms of ENV variables that one can set to force it to use libapreq or cgi pm Thats just because every now and then I switch from one to the other to debug

I also like to do that switch. However, I think that'd
more naturally be done at the level of the application;
the purpose of this module was just to provide a few
CGI.pm-compatible methods via mod_perl2/libapreq2. The
interface used is such that, within an application, one
can do
    my $cgi;
    if ($some_condition_is_met) {
       $cgi = CGI::Apache2::Ajax->new($r);
    }
    else {
       $cgi = CGI->new($r);
    }
    my $foo = $cgi->param("foo");
and so can switch between CGI.pm and mod_perl2/libapreq2
by adjusting $some_condition_is_met; the method calls
on $cgi are intended to be compatible.

        my other comment is the name:
its just a bit confusing as it doesn't really handle a lot of functionality and abstracts other items. perhaps something like CGI::Apache2::AjaxProvider , Apache2::AjaxProvider, or even CGI::AjaxProvider. also , just a thought - but something like that seems more inline with the purpose of your module.

That's a good suggestion. A couple of people off-list also
raised this, and one suggestion was CGI-Apache2-Wrapper.
CGI::Ajax wants it to start with "CGI", so this sounds
like a good name. I've adjusted Apache2-Ajax and
Apache2-Autocomplete to use this if available; all three
packages are now making their way around CPAN.

Thanks!

--
best regards,
Randy

Reply via email to