Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » JDOM User »

RE: [jdom-interest] Issue with xml prolog

Michael Kay

2007-11-23


> <attribute ><value>
> <?xml version="1.0" encoding="ISO-8859-1"?> <note id="1"> HI
> </note> </value></attribute>
>
> The difference here is id="1". Pls explain why it is not
> giving any error on parsing it.

I've no idea. If you find an XML parser that accepts that file without error
then you should raise a bug report, it's a blatant non-conformance. This is
how Xerces reports it:

Error on line 2 column 6 of file:/c:/temp/test.xml:
The processing instruction target matching "[xX][mM][lL]" is not allowed.

Michael Kay
http://www.saxonica.com/

_______________________________________________
To control your jdom-interest membership:
http://www.jdom.org/mailman/options/jdom-interest/youraddr@(protected)
©2008 junlu.com - Jax Systems, LLC, U.S.A.