src/Codeception/Module/XMLRPC.php
public function sendXMLRPCMethodCall($methodName, $parameters = [])
    {
        if (!array_key_exists('Content-Type', $this->headers)) {
            $this->headers['Content-Type'] = 'text/xml';
        }

        foreach ($this->headers as $header => $val) {
            $this->client->setServerParameter("HTTP_$header", $val);
        }

        $url = $this->config['url'];

        if (is_array($parameters)) {
            $parameters = $this->scalarizeArray($parameters);
        }

        $requestBody = xmlrpc_encode_request($methodName, array_values($parameters));

        $this->debugSection('Request', $url . PHP_EOL . $requestBody);
        $this->client->request('POST', $url, [], [], [], $requestBody);

        $this->response = $this->client->getInternalResponse()->getContent();
        $this->debugSection('Response', $this->response);
    }
public function sendXMLRPCMethodCall($methodName, $parameters = [])
    {
        if (!array_key_exists('Content-Type', $this->headers)) {
            $this->headers['Content-Type'] = 'text/xml';
        }

        foreach ($this->headers as $header => $val) {
            $this->client->setServerParameter("HTTP_$header", $val);
        }

        $url = $this->config['url'];

        if (is_array($parameters)) {
            $parameters = $this->scalarizeArray($parameters);
        }

        $requestBody = xmlrpc_encode_request($methodName, array_values($parameters));

        $this->debugSection('Request', $url . PHP_EOL . $requestBody);
        $this->client->request('POST', $url, [], [], [], $requestBody);

        $this->response = $this->client->getInternalResponse()->getContent();
        $this->debugSection('Response', $this->response);
    }
public function sendXMLRPCMethodCall ( $ methodName , $ parameters = [ ] ) { if ( ! array_key_exists ( 'Content-Type' , $ this -> headers ) ) { $ this -> headers [ 'Content-Type' ] = 'text/xml' ; } foreach ( $ this -> headers as $ header => $ val ) { $ this -> client -> setServerParameter ( "HTTP_$header" , $ val ) ; } $ url = $ this -> config [ 'url' ] ; if ( is_array ( $ parameters ) ) { $ parameters = $ this -> scalarizeArray ( $ parameters ) ; } $ requestBody = xmlrpc_encode_request ( $ methodName , array_values ( $ parameters ) ) ; $ this -> debugSection ( 'Request' , $ url . PHP_EOL . $ requestBody ) ; $ this -> client -> request ( 'POST' , $ url , [ ] , [ ] , [ ] , $ requestBody ) ; $ this -> response = $ this -> client -> getInternalResponse ( ) -> getContent ( ) ; $ this -> debugSection ( 'Response' , $ this -> response ) ; }
Sends a XMLRPC method call to remote XMLRPC-server.

@param string $methodName
@param array $parameters
Sends a XMLRPC method call to remote XMLRPC - server .