I don’t think the XMLReader plugin can do that.
But why not use the built-in XML support of javascript (E4X)? It is not used anymore in modern browsers, but In Servoy/Rhino it works great.
You can do something like this:
var xml = <xml><foo>No CDATA</foo><bar><![CDATA[Value inside CDATA]]></bar></xml>;
for each (var node in xml.*) {
application.output(node.valueOf());
}
And you will just get your values, the CDATA tags are stripped away automatically:[attachment=0]e4x.png[/attachment]
I call an external api url
var _client = plugins.http.createNewHttpClient()
var _post = _client.createPostRequest( _url );
_post.setBodyContent( _xmlpost , ‘text/xml’ )
var _response = _post.executeRequest();
var _answer = _response.getResponseBody();
Now the ResponseBody gives me “<?xml…>valuevalue”
What is the best way to get the XML from this. So to get: valuevalue
To read it like json/the way above you mentioned
Because jquery is not available DOMParser is not available.
Or am I missing something