[patch] Net_URL , HTTP_Request

From: Date: Sat, 27 Apr 2002 13:35:20 +0000
Subject: [patch] Net_URL , HTTP_Request
Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-5835@lists.php.net to get a copy of this message
Had to tweak these two classes to get things to work properly. Net_URL did not set the path properly as it would just set the first character of the path if it started with / which is useless if you have more coming after it. HTTP_Request was including files that have moved. Fixed that and along with the Net_URL fix it works fine for my needs right now. Index: Net_URL/URL.php =================================================================== RCS file: /repository/pear/Net_URL/URL.php,v retrieving revision 1.6 diff -u -r1.6 URL.php --- Net_URL/URL.php 5 Apr 2002 21:33:28 -0000 1.6 +++ Net_URL/URL.php 27 Apr 2002 13:27:38 -0000 @@ -129,7 +129,7 @@ // Path if (!empty($urlinfo['path'])) { if ($urlinfo['path'][0] == '/') { - $this->path = $urlinfo['path'][0]; + $this->path = $urlinfo['path']; } else { $this->path .= '/' . $urlinfo['path']; } Index: HTTP_Request/Request.php =================================================================== RCS file: /repository/pear/HTTP_Request/Request.php,v retrieving revision 1.13 diff -u -r1.13 Request.php --- HTTP_Request/Request.php 8 Apr 2002 20:19:36 -0000 1.13 +++ HTTP_Request/Request.php 27 Apr 2002 13:28:29 -0000 @@ -26,8 +26,8 @@ // echo $a->getResponseBody(); // -require_once('Net/Socket.php'); -require_once('Net/URL.php'); +require_once('Net_Socket/Socket.php'); +require_once('Net_URL/URL.php'); define('HTTP_REQUEST_METHOD_GET', 'GET', true); define('HTTP_REQUEST_METHOD_HEAD', 'HEAD', true); -- Kjartan <kjartan@zind.net> (http://natrak.net/) :: "Trespassers will be shot. Survivors will be shot again"

« previous php.pear.dev (#5835) next »