Hi.
I need to read urlencoded data from POST request. So far I have tried
$_POST['name'], but this converts each input %5C to two backslashes
(instead of one) and %00 to \0 (slash zero, not zero byte) for some
reason. Is there any other way to read the data apart from parsing
php://input myself?
Accessing $HTTP_RAW_POST_DATA is similar to reading php://input which
I mentioned in my previous email.
I am not quite sure what is $_POST useful for. It is intended for
reading urlencoded data which it does only in special cases (no \0 or
\5C chars) and everyone has to parse it himself. Did I mis
$_POST is useful for FORM data -- it urldecodes the data, and assumes
it's something somebody would actually type into a FORM. This would
be what 99.9% of websites need and want.
$HTTP_RAW_POST_DATA gives you ALL the raw encoded data to parse as you
see fit. This covers the rest of the needs.
I
3 matches
Mail list logo