Am 23.02.2017 um 14:10 schrieb Hans Hagen:
On 2/23/2017 1:50 PM, Peter Rolf wrote:
Hi,
what is the easiest way to export a lua table (mostly key-value pairs) into a XML file? I found 'lxml.save', but no luck with a converter function. Any help welcome.
kind of obvious:
local t = { a = { b = 1 } }
inspect(table.toxml(t))
Mhhh, tried that among others (always an empty XML document as result). I guess I better start with only a small portion of the original table (~560Kbyte as lua code). Thanks for the pointer :D
----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl ----------------------------------------------------------------- ___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___________________________________________________________________________________