Yesterday I wrote a post about an issue I found with isXML. Lots of good suggestions/ideas were posted in the comments, including one by Rick O which seems to have nailed down the issue. Basically, if you have an invalid tag within a CDATA block, ColdFusion will report the XML as being invalid. The specs say (from what I found), that anything should be allowed in CDATA. It seems like this would be a bug in ColdFusion. Here is a simple sample:
<cfsavecontent variable="test"> <foo> <![CDATA[ <b>fdoo</i ]]> </foo> </cfsavecontent>
The bad I tag at the end is enough to break ColdFusion's isXML function.
Something to look out - and of course - don't forget the issues with xmlFormat as well. xmlFormat will ignore "high" characters (like funky Microsoft quotes) resulting in XML that won't be valid. My toXML CFC has it's own xmlFormat function that tries to get around this.