Hi everybody,
I am using the RESTful Web Service plugin. After making a HTTP request at this url : http://localhost:8080/servoy-service/rest_ws/restful_module/restful_frm/700 i get this response:
<?xml version="1.0" encoding='UTF-8'?>
<lastName>John</lastName>000700<firstName>Doe</firstName>
My problem is that I need as a response a valid XML for which I can control the formatting. Is there any solution for this? Can I send from Servoy a well formatted XML, instead of an object and the XML is created by the webservice?
Thank you!
Best regards, Ionel Ioras, STB
I tried many solutions and found one in the end:
- I created the object that the function ws_read(vID) returns this way:
var vContact = new Object();
vContact.profiles = new Object();
vContact.profiles.individual = new Object();
vContact.profiles.individual.code = foundset.contact_code;
vContact.profiles.individual.nameDisplay = foundset.name_display;
return vContact;
- creating the object this way, the web service returns the xml like this:
<?xml version="1.0" encoding='UTF-8'?>
<profiles>
<individual>
000700
<nameDisplay>Mr. John Doe</nameDisplay>
</individual>
</profiles>
- this is what i needed
![Smile :)]()