XML To Array
Mark Wieder
ahsoftware at sonic.net
Tue Jul 2 19:16:55 EDT 2019
On 7/2/19 2:29 PM, Bob Sneidar via use-livecode wrote:
> Hi all.
>
> I'm revisiting converting XML to Array. Toshiba has an export file for their scan templates in XML format. It's pretty complicated as you can imagine. I was hoping that I could use Trevor's XML to Array functions to get nodes that look something like:
>
> JobTemplates
> GroupList
> Group1
> Template1
> Template2
> Template3...
> Group2
> Template1
> Template2...
What are you hoping to get out of xml-to-array? Given that keys aren't
guaranteed to be unique, I think what you're seeing there makes sense.
Otherwise you'll stand the chance of losing data in translation. If you
don't convert to a numeric form with a concordance, as Trevor has done,
I don't see you you could possibly convert this xml to an array:
<combine class="TV_Show">
<sources>
<agent>com.plexapp.agents.none</agent>
<agent>com.plexapp.agents.localmedia</agent>
</sources>
</combine>
--
Mark Wieder
ahsoftware at gmail.com
More information about the use-livecode
mailing list