You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by John ORourke <jo...@o-rourke.org> on 2008/04/22 01:05:14 UTC

reading yet preserving request body

Hi folks,

I have an MVC-style system which passes the request object to various 
modules until one of the 'accepts' it.

I'm using Apache2::Request to parse incoming form parameters which is fine.

The problem is that some of these modules want to read XML or Multipart 
MIME from the request body, but of course Apache2::Request wants to read 
it too.  If I create my Apache2::Request object, then use $r->read() to 
read the body, then call discard_request_body(), will I be able to have 
my cake and eat it?

thanks
John