_fault = new Zend_XmlRpc_Fault(630); return; } $this->_xml = $xml; $this->loadXml($xml); } /** * Retrieve the raw XML request * * @return string */ public function getRawRequest() { return $this->_xml; } /** * Get headers * * Gets all headers as key => value pairs and returns them. * * @return array */ public function getHeaders() { if (null === $this->_headers) { $this->_headers = array(); foreach ($_SERVER as $key => $value) { if ('HTTP_' == substr($key, 0, 5)) { $header = str_replace(' ', '-', ucwords(strtolower(str_replace('_', ' ', substr($key, 5))))); $this->_headers[$header] = $value; } } } return $this->_headers; } /** * Retrieve the full HTTP request, including headers and XML * * @return string */ public function getFullRequest() { $request = ''; foreach ($this->getHeaders() as $key => $value) { $request .= $key . ': ' . $value . "\n"; } $request .= $this->_xml; return $request; } }