RE: [PEAR] HTTP Client and PHP 5.0.3 Linux

From: Date: Wed, 13 Jul 2005 14:40:40 +0000
Subject: RE: [PEAR] HTTP Client and PHP 5.0.3 Linux
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-19970@lists.php.net to get a copy of this message
I don't think that this method could be called statically. You have to instantiate a Client and then you can call setMaxRedirects : $client =& new HTTP_Client(); $client->setMaxRedirects (3); -----Message d'origine----- De : Luke Barker [mailto:lukebarker@gmail.com] Envoyé : mercredi 13 juillet 2005 16:25 À : pear-general@lists.php.net Objet : [PEAR] HTTP Client and PHP 5.0.3 Linux Hi, I am having problems running a simple POST query from a HTTP::Client $cli request. Each time it gives me what seems to be a OO error from PHP 5...the query used to work as is from my PHP 4 install. code: require_once "HTTP/Request.php"; require_once 'HTTP/Client.php'; # it fails at this line HTTP_Client::setMaxRedirects (3); // line 121 # error given is: Using $this when not in object context in *HTTP/Client.php * on line *121* can anyone help? I have got a single request going OK from HTTP/Request, but I need to use the Client eventually. I have the latest upgraded packages installed for both. thanks Luke ~L~ lukebarker@gmail.com http://www.battez.org --------------------------------------- I'm doggone gonna be with Some real people... ( R & E )

« previous php.pear.general (#19970) next »