Reputation: 74
I have a strange issue with XML formatting.
Is
<SomeObject Name="SomeName" Surname="Surname" Age="23" />
the same as:
<SomeObject>
<Name>SomeName</Name>
<Surname>Surname</Surname>
<Age>23</Age>
</SomeObject>
Could you check and tell me if those two markups mean the same?
Upvotes: 0
Views: 31
Reputation: 163478
One of your snippets uses an element with attributes, the other uses an element with child elements. That's not a formatting difference, it's a different way of modelling your data.
What exactly is your question? If you're asking whether these two snippets are the same, then the answer is no, they aren't.
Upvotes: 1