/** * Adding custom functionality to decode data after * standard prepare functionality * * @return string */ protected function _prepareBody() { $body = parent::_prepareBody(); if (!$this->_urlEncodeBody && $body) { $body = urldecode($body); $this->setHeaders('Content-length', strlen($body)); } return $body; }
/** * Prepare the request body (for POST and PUT requests) * * @return string * @throws Zend_Http_Client_Exception */ protected function _prepareBody() { if ($this->_streamingRequest) { $this->setHeaders(self::CONTENT_LENGTH, $this->raw_post_data->getTotalSize()); return $this->raw_post_data; } else { return parent::_prepareBody(); } }