In fact I found the solution.

The Web service method returns the string that contains the XML document (using the 
toString() function):
e.g <cfreturn toString(MyXMLVar)>

The recipient has just to do four search and replace in the received string to get 
theproper XML docuement.

The four replace are:

replace(receivedXML,"&lt;","<","ALL")
replace(receivedXML,"&gt;",">","ALL")
replace(receivedXML,"&quot;","""","ALL")
replace(receivedXML,"&amp;","&","ALL")

the replacement of the &amp; has to be done at last.

>Hello,
> 
>I have created a Web service that is suppose to return an XML structure.
>Everything seems fine but the all the < > in the SOAP response are escaped.
> 
>I have the feeling that Coldfusion MX escapes this characters to avoid
>problems with the validity of the XML Soap structure.
> 
>Can anyone help me to define the cffunction so that it indicates to
>coldfusion MX that I want to return a XML document and not a simple string.
> 
>Many thanks for your help.
> 
> 
>Eric.
> 
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Message: http://www.houseoffusion.com/lists.cfm?link=i:4:137950
Archives: http://www.houseoffusion.com/lists.cfm?link=t:4
Subscription: http://www.houseoffusion.com/lists.cfm?link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Get the mailserver that powers this list at 
http://www.coolfusion.com

Reply via email to