When applied to an XML document, valid means that it's not only well formed, but also it complies with a given DTD.