Posted Oct 16, 2009 21:47 UTC (Fri) by dlang (✭ supporter ✭, #313)
In reply to: Stanse by oak
Parent article: Stanse
I think the readability depends heavily on the schema that's selected for the XML.
what most people end up using is insane, but I believe that properly used it can be good.
many people do something like
<xml>
<group type='user'>
<name>
data
</name>
<address>
data
</address>
</group>
<xml>
which I agree is horrible to deal with
however if you did something like this instead
<xml>
<user name='data' address='data' />
<xml>
I think it's reasonable.
my view is that if the item of data can only appear once it should be an attribute, only if it can appear multiple times or can have something else inside it should it be an element (and even there I sometimes 'cheat' by making the data be a comma separated list)