?

Log in

No account? Create an account
Ys
ysabel
..:: .::: .:: .::.::.:.: .. ..:: .::: .:: ....

May 2011
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31

Ys [userpic]

Okay, I just found this snippet of XML. There's more, but this should be enough to horrify anyone who understands XML:

<VariableSection><![CDATA[<?xml version="1.0"…

ETA: For those who don't know XML, this is a not-completely-insane way to do a usually-complete-insane thing, namely to embed an XML document inside another XML document. The case where it's being used is not something that could possibly warrant even thinking about something like this.

Tags:
Comments

You ARE stalking me.

I swear I'm not. ysabel is a really good friend. :)

I can stalk you a bit if that'll help any.

Please to 'splain?

See my update.

See my update. I wish it would explode.

*twitch* *TWITCH*

BURN IT WITH FIRE!

See my update.

So, nested xml documents... what's so wrong with it? Was someone specifically trying not to parse the version tag?

Using the XML document in which I found this would require parsing the outer XML document, extracting the inner XML document as a string, and then parsing that document. I can think of very few cases where that's an excusable thing to do to someone, much less a reasonable thing to do.

This isn't one of them, I might add.

Is it an XML doc inside an XML doc, improperly escaped? Or... What?

No, it's properly escaped. It's just a complete XML document nested inside another XML document.

Yo dawg, I heard you liked XML documents, so we put an XML document in your XML document so you can parse while you parse!

Sorry. Had to. ♥

I pity the fool who encounters the first ]]> string!

Or is there a magic way to escape that inside a CDATA?

Whether or not there is, yes, I am appropriately horrified.

Yeah, if the inner document contained a CDATA somewhere inside, it would completely fail.