Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.4.4

Bug #131 bug when url is /
Submitted: 2003-10-20 20:39 UTC
From: leslie at britbus dot org Assigned: avb
Status: Closed Package: HTTP_Request
PHP Version: Irrelevant OS: Windows XP Professional
Roadmaps: (Not assigned)    

 [2003-10-20 20:39 UTC] leslie at britbus dot org
Description: ------------ if the request url is just in the form of, and doesn't have a trailing slash, the output is HTTP 400 Bad Request. I checked the actual request, and it printed as this: GET HTTP/1.1 User-Agent: PEAR HTTP_Request class ( ) Content-Type: application/x-www-form-urlencoded Connection: close Host: Accept-Encoding: gzip Reproduce code: --------------- $req = &new HTTP_Request(''); $req->setMethod(HTTP_REQUEST_METHOD_GET); $req->setURL(''); $req->clearPostData(); $req->sendRequest(); //echo $req->_buildRequest(); $response2 = $req->getResponseBody(); echo $response2; Expected result: ---------------- the website to be printed Actual result: -------------- a 400 Bad Request error is produced


 [2003-10-24 11:18 UTC] avb
Fixed in CVS. Thanks for reporting!