y-man said:
I am trying to get a working XML website.
Why? What's an "XML website" anyway? The web runs on HTML, not XML
(and not even XHTML). If you're doing "web publishing", then do it in
HTML. (Read c.i.w.a.h for the interminable debate over Appendix C)
If you're using some internal XML format for an internal CMS task and
transcoding it into HTML on output, then that's OK. I'd question why
you're using DTD here though, rather than XML Schema or even Relax NG.
As to the benefit of an "XML website" in this incarnation, then I'd
also suggest that your DTD is both idiosyncratic and no more use than
plain HTML would have been. Re-inventing wheels is always bad enough,
but don't do it unless the existing wheel is square and yours is so
much better as to be frictionless!
As an implementation issue of your current page, then the encoding and
its description is dubious. You've tried to specify this in the XML
prolog inside the file itself, but that's really only intended for use
with files, not HTTP documents. You should really specifiy this
explicitly with a HTTP content-type header in the web server's
response.
If you don't specifiy this clearly through HTTP then there's a whole
bunch of rules as to the precedence between the ISO-8859 you've
specified and what various sniffing algorithms try and make of the
document. Chances are that they won't give the answer you expect and it
gets horribly confusing - so set that HTTP header !
I tried to validate it through the w3c validator
Which one? There used to be a W3C XML validator, but I haven't seen it
in years and don't know if it's still there. If you throw your page
into their _HTML_ validator at validator.w3.og then anything could
happen - it's not intended for general XML use and isn't particularly
good at it.
By the looks of things, your file is valid but the encoding isn't
clearly specified and that's itself enough to make the validator choke
on it as a usable web document.