Parse xml document to string

Posted by wweultjes on 25-Mar-2015 09:17

Hello,

In Rollbase it is possible to parse an xml string to an dom.element using rbv_api.parseXML. Is there a also a method to do the reverse action? convert the dom.element to an xml String? I'm doing this in a server side trigger.

Regards,

Wilco Weultjes.

Posted by Orchid Corpin on 25-Mar-2015 11:04

Hi Wilco,

Yes, rbv_api.parseXML can parse string into XML format, doing the reverse I think you can do like var x = String("<your xml dom.elements>");

Hope this may help.

Regards,

Orchid

All Replies

Posted by Orchid Corpin on 25-Mar-2015 11:04

Hi Wilco,

Yes, rbv_api.parseXML can parse string into XML format, doing the reverse I think you can do like var x = String("<your xml dom.elements>");

Hope this may help.

Regards,

Orchid

Posted by pvorobie on 25-Mar-2015 11:11

We don't have reverse method, sorry.

Posted by Orchid Corpin on 25-Mar-2015 13:05

Yes, as Pavel said there is no API for reverse, maybe you can try a javascript method to convert it to string as the example above. If you want this to be included in the Rollbase API in the future, please file an idea in our Ideas page Here.

This thread is closed