-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
xml2lua.toXml() : Duplicated XML tags is broken when converting from Lua to XML #87
Comments
I couldn't reproduce the behavior. Use this lua table to achieve the xml result. local xml2lua = require("xml2lua")
local tagtable = { tag = { tag1 = { [1] = 'A', [2] = 'B' } } }
print(xml2lua.toXml(tagtable)) <tag>
<tag1>A</tag1>
<tag1>B</tag1>
</tag> |
I have a similar bug:
so I try to load xml and the convert it back to xml, the response I get is:
as you see
instead of this
|
UPD: I found out this problem happening on v.1.5-2 (the latest version that is currently available on |
Use case : create a lua table and convert it to XML with duplicated tags
based on
xml2lua/example3.lua
we could expect :would give :
but it gives insead :
The easyest way to test it is to append the following line at the end of
xml2lua/example3.lua
(select the 3rd test by uncommenting line 18) :The text was updated successfully, but these errors were encountered: