Re: [PHP] fsock sending bad request

2003-10-23 Thread Raditha Dissanayake
Hi hey Curt, I missed that one. Daniel have you looked at RFC 2616? Curt Zirzow wrote: * Thus wrote [EMAIL PROTECTED] ([EMAIL PROTECTED]): Hi there the following code doesnt seem to work, i am getting a bad request sent back from the server, what could be the problem of something so simple ? $h

Re: [PHP] fsock sending bad request

2003-10-23 Thread Curt Zirzow
* Thus wrote [EMAIL PROTECTED] ([EMAIL PROTECTED]): > Hi there the following code doesnt seem to work, i am getting a bad request > sent back from the server, what could be the problem of something so > simple ? > > $header .= "POST test.php HTTP/1.0\r\n"; > $header.= "Host: host\r\n"; > $header .

Re: [PHP] fsock sending bad request

2003-10-23 Thread Raditha Dissanayake
hi, deo> $header.= "$req\n"; Tom is right but as usual IIS is wrong and expects it :-( so better to use it anyway. deo> $fp = fsockopen("host", "80", $errno, $errstr, $timeout = 30); errno and errstr will not be set unless you pass it by reference. deo> $header.= "Host: host\r\n"; Host header

Re: [PHP] fsock sending bad request

2003-10-23 Thread daniel
$req = "&field=1"; its the data i need to post > Hi, > > Thursday, October 23, 2003, 7:58:19 AM, you wrote: > deo> Hi there the following code doesnt seem to work, i am getting a > bad request deo> sent back from the server, what could be the problem > of something so deo> simple ? > > deo> $heade

Re: [PHP] fsock sending bad request

2003-10-22 Thread Tom Rogers
Hi, Thursday, October 23, 2003, 7:58:19 AM, you wrote: deo> Hi there the following code doesnt seem to work, i am getting a bad request deo> sent back from the server, what could be the problem of something so deo> simple ? deo> $header .= "POST test.php HTTP/1.0\r\n"; deo> $header.= "Host: host\