xml parsing error

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

xml parsing error

Wesley Li-Wei Chou(周立瑋)
While I am parsing .xml files come with components, I always get error from my parser.
Than I use http://www.w3.org/2001/03/webdata/xsv to validate it, the output shows that the problem is in component.dtd.
 
Valication output:
Error: Encoding declaration is required in text declaration
 in unnamed entity at line 1 char 23 of http://sources.redhat.com/sid/component.dtd
 
If I remove the <?xml version="1.0" ?> at first line or modify it as <?xml version="1.0" encoding="UTF-8"?>, it turns out to be ok.