I've been working on a project that concerns connecting to a SOAP service and grab data from there rather than a DB I have direct access with. Whenever I go to the page for this code I receive Did not receive a '200 OK' response from remote server. (HTTP/1.1 500 Internal Service Error)
and upon turning debug
flag on I see
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"><SOAP-ENV:Body><SOAP-ENV:Fault><faultcode>SOAP-ENV:VersionMismatch</faultcode><faultstring>Wrong Version</faultstring></SOAP-ENV:Fault></SOAP-ENV:Body></SOAP-ENV:Envelope>
Here's the code for my SOAP client.
class Game_model extends CI_Model {
function __construct()
{
$this->key = 'someKeyYouCantKnow:)';
// Call model construct
parent::__construct();
}
function check_key()
{
$this->load->library('xmlrpc');
$this->xmlrpc->server('http://some.url.I.cant/share/entry.php', 80);
$this->xmlrpc->method('checkKey');
$request = array(
array('apiKey' => $this->key)
// Have tried encaps`ing in another array and specifying
// as a struct as well, or leaving out 'apiKey' all together
);
$this->xmlrpc->request($request);
$this->xmlrpc->set_debug(TRUE);
if(!$this->xmlrpc->send_request())
{
return $this->xmlrpc->display_error();
}
else return $this->xmlrpc->display_response();
}
}