I am trying to convert XML to a table. First, I tried to convert the example from Docs/XMLParser/lom.html but couldn't get it to run. I tried:
Code: Select all
@REQUIRE "xmlparser"
s = [[<abc a1="A1" a2="A2">inside tag abc</abc>]]
tab = xmlparser.lom.parse(s)
Then, I found this post which explains how to use DeserializeTable() to do exactly what I wanted:
viewtopic.php?f=18&t=2260&hilit=xmlparser
Unfortunately, I can't even get the example for SerializeTable() to run:
Code: Select all
@REQUIRE "xmlparser"
t = {test = 1, bla = "Hello World", table1 = {table2 = {table3 = {af = "test"}}}, cool = "Hello & How are you\"'<>&", 1, 2, 3, 4, 5,
subnode = {1,2,3,4,5, yooguys = 0.4567}, yeah = "12345", functest = Function(a, b, c)
DebugPrint("Hello World this is a test", a, b, c) EndFunction}
a$ = SerializeTable(t, "xmlparser")
DebugPrint(a$)
The plugin is installed, of course, and working (tested with this example: viewtopic.php?f=26&t=3235&p=16569&hilit ... ser#p16569).
Can anyone please try to get the SerializeTable() example to work with Hollywood 9?
Cheers,
Michael