I am new to CodeIgniter and Xmlrpc in general, so i have a fairly basic question. I wish to make a request to a web service that expects data of the form
POST /LabelService/EwsLabelService.asmx/ChangePassPhraseXML HTTP/1.1
Host: www.envmgr.com
Content-Type: application/x-www-form-urlencoded
Content-Length: length
changePassPhraseRequestXML=<ChangePassPhraseRequest> ...
</ChangePassPhraseRequest>
and some of the options that go in that chunk of xml are nested two layers deep.
Meanwhile, at http://codeigniter.com/user_guide/libraries/xmlrpc.html, I only see requests getting passed as arrays. Do these get converted into xml of the right kind? Do I just nest tons of arrays? Would I really have (value, type) pairs as each side of xml key value pairs?
To be more clear: will it work if I be like $request =
array(array(“ChangePassPhraseRequest”, ‘string’) => (array(“”, ‘string’)),
array(array(“RequesterID”, ‘string’) => array(“313325”, ‘string’))… etc
that seems like what the docs are telling me, but it also seems too horrible to be true.
Ended up using the REST API: http://codeigniter.com/forums/viewthread/73080/
It accepts arguments in the form of a simpleXML object, which is much nicer to construct than a wall of plaintext xml or nested arrays.