Friday, January 18, 2008

Receiving Base64 content with in a soap message in WSF/PHP

When you receive a soap message with mtom, the receiving WSMessage object will contain the two properties using which you can extract the binary content. These two are attachments property and cid2ContentType property. But When if you want to receive the binary content received converted to base64, WSF/PHP can do that too.

All you need to do is to set the responseXOP option in the WSClient options array to FALSE.

Eg.

$client = new WSClient(
array( "to" => "some end point",
"useMTOM" => TRUE,
"responseXOP" => TRUE));

No comments:

Post a Comment