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 $header .= POST

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 is

Re[2]: [PHP] fsock sending bad request

2003-10-23 Thread Tom Rogers
Hi, Thursday, October 23, 2003, 10:32:18 PM, you wrote: deo $req = field=1; deo its the data i need to post But you are sending it twice, and there has to be a cr/lf between the header and the data I think. -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

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 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 ?

[PHP] fsock sending bad request

2003-10-22 Thread daniel
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 .= Content-Type: application/x-www-form-urlencoded\r\n; $header .=

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\r\n;