title: Why doesn't the XML validate to the DTD
body: <p>DTD:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  
  &lt;!ELEMENT language (definition, tu, tuv, seg) &gt;
  &lt;!ELEMENT definition ANY &gt;
  &lt;!ELEMENT tu ANY &gt;
  &lt;!ELEMENT tuv ANY &gt;
  &lt;!ELEMENT seg (#PCDATA) &gt;
  &lt;!ATTLIST tu id CDATA #REQUIRED &gt;
  &lt;!ATTLIST tuv lang CDATA #REQUIRED &gt;
  </code></pre>
  
  <p>XML:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;!DOCTYPE language SYSTEM "language.dtd"&gt;
  
  &lt;definition&gt; # This is the line that seems to be the problem
      &lt;tu id="webpage-title-text"&gt;
          &lt;tuv lang="en"&gt;
              &lt;seg&gt;Demo CMS&lt;/seg&gt;
          &lt;/tuv&gt;
      &lt;/tu&gt;
  &lt;/definition&gt;
  </code></pre>
  
  <p>The error message I get is:</p>
  
  <blockquote>
    <p>Document root element "definition", must match DOCTYPE root
    "language". [4]</p>
  </blockquote>
  
  <p>My Questions:</p>
  
  <ol>
  <li>What is the reason so that the XML is not considered valid against
  the current DTD?  </li>
  <li>What I have missed in the DTD?  </li>
  <li>Could anyone
  recommend a good place to take as a resource of learning how to use
  DTDs, Schemas and etc.</li>
  </ol>