Accessing post data
Fred Appelman <[email protected]> Wed, 3 Jun 2009 22:09:39 +0200
| Newsgroups | gmane.comp.apache.mod-ruby |
|---|---|
| Message-ID | <[email protected]> |
Hi,
I have implemented a couple of projects using mod_ruby and I really
like it. I have now stumbled upon a problem which I can't seem to solve.
I am trying to built a server that will respond to XML posts. I run
into two problems:
1. Mod_ruby doesn't seem to like/understand the Content-Type text/xml.
I get the following error in the logs:
[Wed Jun 03 22:04:03 2009] [error] [client 10.0.83.132] [libapreq]
unknown content-type: `text/xml'
Is there an option to make Mod_ruby aware of this content type?
2. Once I have the data I am able to see that the post data has a size
of 250 bytes. Also the request_method confirms there is POST data.
I cannot find any method to actually access these bytes. The
method read returns nil and the functions gets, readline and readlines
all claim they are private to Apache::Request.
Since there is no documentation I am out of ideas. Does anyone
know how to access the POST data?
Fred