[Xsltforms-support] Parsing XML from textarea
Brought to you by:
alain-couthures
From: William V. <wve...@vi...> - 2013-10-21 17:24:25
|
Hi everybody, I'm building an XForms where the user could be able to paste XML code in a textarea and then apply an XSL transformation to the pasted code. In order to be able to do it, I tried two alternatives with no success: 1. Parse the XML code and store it in an instance (there is no function to parse xml text to instances) 2. Directly apply the transformation to the XML code and store the result in an instance (the transform() function only accepts nodes as input, not plain text. The missing piece is how to parse the content of the textarea. XPath 3.0 defines serialize()to convert an instance to text and parse-xml() to do the reverse process. XSLTForms implements the serialize() function, but the parse-xml() is not available. Some body knows a shortcut to do this? Thanks in advance, William David Velásquez Director de Investigación y Desarrollo Visión Tecnológica S.A.S. www.visiontecnologica.com<http://www.visiontecnologica.com> Follow me @williamda |