I would like to add a note to this, that this works in general, but
the thing which actually triggers the setting of $HTTP_POST_RAW_DATA
is a not recognized mime-type.

Bolke

-----Oorspronkelijk bericht-----
Van: nik [mailto:[EMAIL PROTECTED]]
Verzonden: Friday, April 27, 2001 3:04 PM
Aan: [EMAIL PROTECTED]
Onderwerp: Re: [PHP] Extracting the body of the http request entity?
found it!


>
> According to the w3c docs, POSTed  content is sent in the "request
> entity body".  Since the request has a header, it's logical that it can
> have a body too :-) but I don't see any PHP functionality for getting at
> it. Someone in another group suggested accessing a variable called
> $HTTP_RAW_POST_DATA, but that doesn't seem to exist when I POST data to
> either of my test systems, which are Linux/Apache or Win98/PWS.
>
> PHP itself must be able to extract the POSTed data - it does so when
> saving a POSTed file to its temporary location - but this function don't
> seem to be exposed in the API... is it?

Sorry to answer my own question!

If you POST an html form with input elements, these are parsed by PHP into
variables, and the data is discarded.  BUT if you POST raw data from a
generic http component, without sending name-value pairs, this data is
exposed in $HTTP_RAW_POST_DATA.

nik


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to