Santosh Nagarajan - 2007-10-11 06:12:34 - In reply to message 2 from Manuel Lemos
Hi Manuel Lemos,
Thanks for your interest and quick reply.
No... I tried to capture the data with $_POST method but it is not getting me any piece of data for above mentioned case. Could you suggest me with few lines of sample code ? if I have done any mistake in my code I can correct.
Santosh Nagarajan - 2007-10-11 06:12:54 - In reply to message 2 from Manuel Lemos
One more information I would like to furnish. The browser is not sending above said data thru any FORM. In case of a FORM we know the data type and their respective variables. We can easily capture these kind of data by $_POST method. I too agree.
But this is not the case. The browser is just sending some plain text like data with above mentioned mime type. It is not associated with any FORM or any variable to capture. It is actually an output of certain process carried out by a customized browser. We need to pass on this data to another script for maintaining a log.
Santosh Nagarajan - 2007-10-11 07:19:57 - In reply to message 5 from Manuel Lemos
No it is not AJAX request. It is a regular php POST request. The data being sent is in plain text format. But to be inline with certain standards, the browser is sending urlencoded MIME type along with the data.
OK.. let us look from a different angle. How to capture incoming stream of text data (which always varies in length) being received by a php script and dump it into a text file for further analysis?
Santosh Nagarajan - 2007-10-11 18:58:21 - In reply to message 7 from Manuel Lemos
It is a real browser. But it has a in-built download client, which handles a regular HTTP download and OMA download. OMA download will have a download descriptor file which gives details about the object being downloaded. Hence this download client is integrated part of the browser, I am referring it as browser.
What I mean by text data is that, even though the data is urlencoded it is in a readable format like 'plain/text'. Actually it is, indeed, urlencoded.
Certainly it is not intended to break any security measures. It is intended to download various types of objects onto client device and then send the feedback of the downloaded process on to a script (in my case it is test.php) to monitor statistics/status about the downloaded object.
Manuel Lemos - 2007-10-11 19:02:23 - In reply to message 9 from Santosh Nagarajan
The way you presented your sample values it is not correctly URL-encoded to be accepted as a request of content-type application/x-www-form-urlencoded . That is why PHP discards your request and the values do not appear in POST.
To make it work you must emulate a form POST request properly. So, it must be of the form:
Since all values are URL encoded, there must be no line breaks. Everything is in a single line.