php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #24028 Reading raw post message by php://input
Submitted: 2003-06-04 22:24 UTC Modified: 2006-03-31 01:37 UTC
From: florianophoneltd at yahoo dot com Assigned:
Status: Closed Package: CGI/CLI related
PHP Version: 4.3.2 OS: win32 only
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: florianophoneltd at yahoo dot com
New email:
PHP Version: OS:

 

 [2003-06-04 22:24 UTC] florianophoneltd at yahoo dot com
I wrote a routine "postrawdata.php" for displaying HTTP raw request message. 
<?php 
$putdata = fopen( "php://input" , "rb" ); 
while(!feof( $putdata )) 
echo fread($putdata, 4096 ); 
fclose($putdata); 
?> 

It works properly when using a socket program to post something to it. 

But submitting from a simple HTML below will make it dead, even http headers were not sent back, the behavior of brwoser is just waiting before timeout, I have tested it under IE 6.0 and Netscape 7.0 , any suggestion is appreciate. 

<body> 
<form name="form1" method="post" action="postrawdata.php"> 
<input type="text" name="name" > 
<input type="submit" name="Submit" value="Submit"> 
</form> 
</body> 

I think PHP does not send correct responding data to browser, or it does not disconnect the HTTP channel, that makes browsers to wait , whereas my socket client do disconnect when finished.

Thanks,

William Hong

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-06-24 12:58 UTC] sniper@php.net
Fixed -> closed. 
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Mar 28 16:01:29 2024 UTC