Hi Federico,

If you have access I would post it as an improvement level issue to JIRA. At 
the moment I'm using a subclass which adds methods like resetHeaders(). I need 
this functionality otherwise earlier uses of the Zend_Service_Abstract client 
(which is held statically for reuse) end up contaminating future requests (e.g. 
if a prior request sets an Accept header it can't be removed without the 
subclassed method, and would in its absence play havoc in web services which 
use that header to determine what document type to return).

I'm not sure I'd class it as a bug. This behaviour is not unexpected given the 
documentation, and it should be obvious that headers are not parameters - so 
it's a possible improvement rather.

Regards,
Pádraic

 
Pádraic Brady
http://blog.astrumfutura.com
http://www.patternsforphp.com


----- Original Message ----
From: Federico Galassi <[EMAIL PROTECTED]>
To: Matthew Weier O'Phinney <[EMAIL PROTECTED]>
Cc: [email protected]
Sent: Saturday, June 23, 2007 6:31:13 PM
Subject: Re: [fw-general] Zend_Http_Client big problem - LONG


On 23/giu/07, at 18:33:41, Matthew Weier O'Phinney wrote:

> -- Federico Galassi <[EMAIL PROTECTED]> wrote
> (on Saturday, 23 June 2007, 03:49 PM +0200):
>> Hello,
>> i started to write this e-mail as a bug report. For the record, the
>> bug is:
>> --- code ---
>> $uri = "http://www.google.com/";;;
>> $client = new Zend_Http_Client();
>> $client->setUri($uri);
>> $client->request('POST');
>> echo $client->getLastRequest();
>> $client->request('GET');
>> echo $client->getLastRequest();
>
> You need to call $client->resetParameters() between subsequent  
> requests.
> This is clearly indicated in the manual.

Unfortunately, resetParameters() doesn't reset the content type, but  
that would
just make it a simple bug. Does it make sense to leave the component  
in a broken
state unless an action is taken by the user, even if it's stated by  
documentation?
I mean, if it has to be done, why isn't it done implicitly after  
every request is made?

Thank you,
Federico









      
____________________________________________________________________________________
Park yourself in front of a world of choices in alternative vehicles. Visit the 
Yahoo! Auto Green Center.
http://autos.yahoo.com/green_center/ 

Reply via email to