Re: retrieve POST body?
| From: | Richard Lynch | Date: | Thu, 19 Apr 2007 04:26:19 +0000 |
| Subject: | Re: retrieve POST body? | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-253240@lists.php.net to get a copy of this message | ||
On Wed, April 18, 2007 11:03 am, Justin Frim wrote:
> André Medeiros wrote:
>
>> Reading from php://input on a webserver will retrieve the Body of
>> the
>> HTTP Request.
>
> Not for me it doesn't.
> That only seems to work when the form is submitted as
> application/x-www-form-urlencoded. When the form is submitted as
> multipart/form-data, php://input is blank.
One possibly super ugly hack...
You could maybe write your own middle-ware HTTP server thingie with
some kinda socket functions, do what you want with the input, and then
pass it on to PHP somehow...
I think you might maybe be better off putting in a Feature Request to
get RAW_HTTP_POST_HEADERS or whatever it is turned "on" for
multipart/form-data, or even declaring it a Bug.
It might just get labeled bogus as a bug though...
You may even have some luck looking at PHP source to try to submit a
patch for it...
Doesn't seem like it would be THAT hard to do, once you find the dang
lines of C code that do file upload, and the other lines that do the
RAW_HTTP thing...
'Course, it would take me months just to find those lines of code,
knowing me. :-v
--
Some people have a "gift" link here.
Know what I want?
I want you to buy a CD from some indie artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?