Search code examples
xmldtd

XML Validator issue with "entity value required"


<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE head [
<!ENTITY header ANY >
<!ENTITY top ANY >
<!ENTITY label ANY >
<!ENTITY scope (#PCDATA) ANY >
]>

i don't know how to fix it. what is the entity value??


Solution

  • The error is telling you that it's expecting a value to appear in quotes following the ENTITY name.

    Instead of ENTITY, are you sure that you aren't declaring ELEMENT?

    <?xml version="1.0" encoding="UTF-8" ?>
    <!DOCTYPE head [
    <!ELEMENT header ANY>
    <!ELEMENT top ANY>
    <!ELEMENT label ANY>
    <!ELEMENT scope (#PCDATA)>
    ]>