Re: [xsl] DTD error

Subject: Re: [xsl] DTD error
From: "Gav..." <brightoncomputers@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 6 Nov 2007 12:00:39 +0900 (WST)
<quote who="oryann9">
> Can anyone help me with this error I cannot find?
> thank you much!
>
> Your XML document   has an error:
> Expected an element name
> line: 12
> character: 22
>
>
> <?xml version="1.0" encoding="utf-8"?>
>
> <!-- Define Doc Type definition -->
> <!DOCTYPE CONTACTS [
> <!ELEMENT CONTACTS (PERSON)>
> <!ELEMENT PERSON (FIRSTNAME,LASTNAME,PHONE+)>
> <!ELEMENT FIRSTNAME (#PCDATA)>
> <!ELEMENT LASTNAME  (#PCDATA)>
> <!ELEMENT PHONE     (#PCDATA)>
> <!ATTLIST PHONE
>   TYPE CDATA #REQUIRED>
> <!ELEMENT WORKADDR  (#CDATA)>   <!-- LINE 12 IS HERE -->
> <!ELEMENT EMAIL     (#PCDATA)>
> <!ATTLIST EMAIL
>   TYPE CDATA #REQUIRED>
> <!ELEMENT TIMEZONE  (#PCDATA)>
> <!ELEMENT OTHERINFO (#CDATA)>
> ]>
>
> <!-- Begin XML user data -->
>
> <CONTACTS>
>     <PERSON>
>         <FIRSTNAME>Jeff</FIRSTNAME>
>         <LASTNAME>XXXX</LASTNAME>
>         <PHONE TYPE="HOME"> 9,234 876-90XX</PHONE>
>         <PHONE TYPE="WORK"> 9,234 767-78XX</PHONE>
>         <PHONE TYPE="CELL"> 9,234 778-67XX</PHONE>
>         <WORKADDR>Zsoft 23400 Park Place, XXXXX</WORKADDR>
>         <EMAIL TYPE="WORK">jXXXX</EMAIL>
>         <EMAIL TYPE="HOME">jXXXXXX</EMAIL>
>         <TIMEZONE>EST</TIMEZONE>
>         <OTHERINFO>Linux Admin, Perl Guru</OTHERINFO>
>     </PERSON>
> </CONTACTS>

It seems you have included <WORKADDR> , <EMAIL>, <TIMEZONE>, <OTHERINFO>
inside your <PERSON> element when they are not declared as such in the
DTD. They do not look like they are in the <CONTACTS> element either. They
are in the doctype, but belong to no element. You'll need to declare them
on the PERSON element if you want to include them inside the PERSON Div.

Warning, I'm a little rusty, but that's what it looks like to me at least.

Gav...




>
>
>
>
>
>
>
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
>
>


-- 
Gav...

Current Thread