|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Wellformed?
Just a quick sanity check I am tying to work on some conformance and want to
make sure I am correct:
The following is wellformed:
===================
<!DOCTYPE doc [
<!ENTITY e "<foo bar1:att='att' bar2:att='att'>test</foo>">
]>
<doc xmlns:bar1="http://www.example1.org"
xmlns:bar2="http://www.example2.org">
<child>&e;</child>
</doc>
But the following is not:
================
<!DOCTYPE doc [
<!ENTITY e "<foo bar1:att='att' bar2:att='att'>test</foo>">
]>
<doc xmlns:bar1="http://www.example.org"
xmlns:bar2="http://www.example.org">
<child>&e;</child>
</doc>
I have even tried:
===========
<!DOCTYPE doc [
<!ELEMENT doc (child)>
<!ATTLIST doc xmlns:bar1 CDATA #IMPLIED
xmlns:bar2 CDATA #IMPLIED>
<!ELEMENT child (foo)>
<!ELEMENT foo (#PCDATA)*>
<!ATTLIST foo bar1:att CDATA #IMPLIED
bar2:att CDATA #IMPLIED>
<!ENTITY e "<foo bar1:att='att' bar2:att='att'>test</foo>">
]>
<doc xmlns:bar1="http://www.example1.org"
xmlns:bar2="http://www.example2.org">
<child>&e;</child>
</doc>
Basically, I am getting errors (even for the WF files) and the results are
all over the map. I knew that expansion of entity references (and WF
checking therein) was spotty-- but combine that with namespace scoping and
things get downright crazy. It seems that only Xerces handles this the way I
would expect... but then I am not sure that is right. The XML Rec claims
that the literal must be WF on it's own-- is that possible with a colon in
one of the attribute names (without a namespace decl?). Maybe the MSXML
parser which claims that there is an undeclared prefix is more correct.
Pointers to any documents exploring this are very welcome.
Thanks,
Jeff Rafter
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








