Hello,

With something like that :
while (ap_get_brigade(r->input_filters, brigade, AP_MODE_READBYTES, APR_BLOCK_READ, len) == APR_SUCCESS) {
   apr_brigade_flatten(brigade, buf, &len);
   apr_brigade_cleanup(brigade);
   tlen += len;
   if (tlen == count_bytes || !len) {
       break;
   }
   buf += len;
   len = count_bytes - tlen;
}


----- Original Message ----- From: "Phil Endecott" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Thursday, February 02, 2006 11:45 PM
Subject: Accessing POST request body from a module


Dear All,

I am porting some CGI code to run as a module. It is all pretty straightforward, except that I can't work out how to get at a POST request's body. The CGI code reads from stdin, which doesn't seem to be the right thing to do in the module. I'm probably missing something obvious; maybe I'm not searching for the right keywords. Can someone point me in the right direction?

Many Thanks,

--Phil.




Reply via email to