Message

foo should not have text (all data is in attributes)

Explanation

Some elements express their data in enclosed text, for example:

<id>urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6a</id>

Others express their data in attributes, for example:

<link href="http://example.org/"/>

This may create confusion.

Solution

Check the specification (example) for the correct way to encode this element.

Not clear? Disagree?

You might be able to find help in one of these fine resources.