[eluser]duffy0[/eluser]
I am using XML-RPC to open my development environment for my friends to build on, but I can't get CI to return the user's id from a encrypted cookie.
The method is initializing, but only returns an empty array like this:
Array ( [userID] => )
Here is my code:
Code:
function getLoggedInUser() {
/* Load the XML-RPC library and others. */
$this->load->library('xmlrpc');
$this->load->library('encrypt');
/* Send Responce. */
$cookie = $this->encrypt->decode($this->input->cookie('userID'));
$response = array(
array(
'userID' => array($cookie , 'string')
),
'struct'
);
return $this->xmlrpc->send_response($response);
}
Am I missing something??