Web Service Request

1
I have created a webservice call that outputs XML like this: ?xml version="1.0" encoding="utf-8"?> <soapenv:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <soapenv:Body> <axis2ns3:QuickApplicationContract xmlns:axis2ns3="urn:DA-InternetLink-Service"> <axis2ns4:input xmlns:axis2ns4="urn:DA-InternetLink-Schema"> <axis2ns4:ProductId><![CDATA[1]]></axis2ns4:ProductId> <axis2ns4:PromotionalCode><![CDATA[10070139]]></axis2ns4:PromotionalCode> <axis2ns4:ApplicationType><![CDATA[Quick]]></axis2ns4:ApplicationType> <axis2ns4:PersonalInfo> <axis2ns4:IDNumber><![CDATA[8407230375]]></axis2ns4:IDNumber> <axis2ns4:Name><![CDATA[a]]></axis2ns4:Name> <axis2ns4:Surname><![CDATA[b]]></axis2ns4:Surname> <axis2ns4:HomeTelephoneNumber> <axis2ns4:Code><![CDATA[null]]></axis2ns4:Code> <axis2ns4:Number><![CDATA[null]]></axis2ns4:Number> </axis2ns4:HomeTelephoneNumber> The Question: Why is Mendix generating CDATA sections for the values? Regards Hardy
asked
2 answers
1

See this. CDATA is text data that should not be parsed by the XML parser.

answered
1

You don't strictly need CDATAs around these elements. We add them because it's easier/more straightforward than checking whether the string actually needs them or not.

answered