in reply to Does CGI::Application expose a HTTP::Request object?

Why? Running C::A under CGI::Fast, at least I am unable to get access to a request's Headers and Content... And further, I need to feed a HTTP::Request object, with it's uri(), method(), etc. methods to a module..

Are you using CGI::Application::FastCGI?

  • Comment on Re: Does CGI::Application expose a HTTP::Request object?

Replies are listed 'Best First'.
Re^2: Does CGI::Application expose a HTTP::Request object?
by isync (Hermit) on Aug 11, 2010 at 13:04 UTC
    No. I am using:
    #!/usr/bin/perl use CGI::Fast(); use MyApp; use utf8; # fastcgi usage as told in: http://cgiapp.erlbaum.net/index.cgi?FastCG +I while( my $q = new CGI::Fast ){ $q->header(-charset => 'utf-8'); my $app = new Engine( QUERY => $q ); $app->run(); }

    Back then, when I started using C::A under fcgi, I think I had issues with C::A::FastCGI initializing things which should only run once under fcgi over and over. Which resulted in the above DIY solution and a $self->{initialized} = 1 flag later on on code which should really run only once.