httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve <vald...@earthlink.net>
Subject Re: How to retrieve the posted variables using the apache module...
Date Mon, 12 Feb 2007 17:29:33 GMT
You should take a look at ap_setup_client_block, ap_should_client_block and
ap_get_client_block.

Here is a small code snippet that should get you started...

 static int BUFSIZE = 65536;
        
 if ( ap_setup_client_block(r, REQUEST_CHUNKED_DECHUNK) == OK )
 {
     if ( ap_should_client_block(r) )
     {
         apr_size_t bytes ;
         char* myBuffer = (char *)apr_pcalloc(r->pool,
sizeof(char)*BUFSIZE);
         do
         {
               bytes = ap_get_client_block(r, myBuffer, BUFSIZE) ;
         }
         while ( bytes );
         ap_rputs( "Post Data: <font color=blue>" , r );
         ap_rputs(myBuffer, r);
         ap_rputs( "</font>\r<BR>\r" , r );
     }
  }



on 12/2/07 12:36 AM, Devender Reddy at mudhiganti123@gmail.com wrote:

> Hi Joe,
> 
>   Thanks  for your reply. Actually, I dumped all the data that is
> there in request_rec->header_in datastructure, but still I couldn't
> find the Posted variables in that datastructure.

[Snip]




Mime
View raw message