Lines Matching +full:server +full:-
10 * This implements a XML-RPC client using our own HTTPClient
24 … public function __construct($server, $path = false, $port = 80, $timeout = 15, $timeout_io = null) argument
26 parent::__construct($server, $path, $port, $timeout, $timeout_io);
29 $this->posturl = $server;
31 $this->posturl = 'http://' . $server . ':' . $port . $path;
34 $this->httpClient = new HTTPClient();
35 $this->httpClient->timeout = $timeout;
43 $length = $request->getLength();
44 $xml = $request->getXml();
46 $this->headers['Content-Type'] = 'text/xml';
47 $this->headers['Content-Length'] = $length;
48 $this->httpClient->headers = array_merge($this->httpClient->headers, $this->headers);
50 if (!$this->httpClient->sendRequest($this->posturl, $xml, 'POST')) {
51 $this->handleError(-32300, 'transport error - ' . $this->httpClient->error);
56 if ($this->httpClient->status < 200 || $this->httpClient->status > 206) {
57 … $this->handleError(-32300, 'transport error - HTTP status ' . $this->httpClient->status);
62 $this->message = new Message($this->httpClient->resp_body);
63 if (!$this->message->parse()) {
65 return $this->handleError(-32700, 'Parse error. Message not well formed');
69 if ($this->message->messageType == 'fault') {
70 return $this->handleError($this->message->faultCode, $this->message->faultString);
84 return $this->httpClient;