Php HTTP_RAW_POST_DATA (to) original address: http://www.phpman.com.cn/archives/143
The Content-Type = text/xml Type is used to submit an xml document Content to the php server. how can I obtain the POST data.
The RAW/uninterpreted http post information can be accessed: $ GLOBALS ['http _ RAW_POST_DATA '] This is useful in cases where the post Content-Type is not something PHP understands (such as text/xml ).
Because PHP only recognizes the application/x-www.form-urlencoded standard data type by default, the content of the type such as text/xml cannot be parsed as $ _ POST array, so the prototype is retained, it is sent to $ GLOBALS ['http _ RAW_POST_DATA '] for receiving.
Another php: // input can also implement this function.
Php: // input allows reading original POST data. Compared with $ HTTP_RAW_POST_DATA, it puts less pressure on the memory and does not require any special php. ini settings. Php: // input cannot be used for enctype = "multipart/form-data ".
Application
A.htm
------------------
Post. php
----------------------------