Redirection

The maxdirects configuration setting is an integer indicating the maximum number of redirections to perform before terminating. Upon termination, the client will simply return the last response it received.    The isRedirect method of

Zend_Http_Response returns true for responses with a 300-level status code.

Sections 10.3.2 and 10.3.3 of RFC 2616 indicate that when a redirection occurs, both the request method and parameters should be retained. In practice, most clients don’t behave this way. Instead, parameters are cleared and the method reverts to GET. For consistency with other clients, Zend_Http_Ctient behaves this way by default. To force it to be compliant with the RFC, the st rict redirects configuration setting can be set to t rue.


© Zend_Http_Client — Web Scraping

>>> Back to TABLE OF CONTENTS <<<
Category: Article | Added by: Marsipan (01.09.2014)
Views: 313 | Rating: 0.0/0
Total comments: 0
avatar