This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: CDATA block to node set.


Michael Kay wrote:
>>I know that my question may seem that of a delusional madman.
>>But I'm well aware of what CDATA is, I had just hoped to access it
>>the same way one can access data from a URL:
> 
> 
> 
> Well, you can. The CDATA contains a string. If this string is well-formed
> XML, you can turn it into a tree by parsing it. Saxon 7.1 allows you to do
> this using saxon:parse(). But it still begs the question: the purpose of
> CDATA is to say "the stuff in here isn't markup", so if it is markup, why
> are you putting it in CDATA?

Because I would like to parse my language for validity. Part of the
language definition allows arbitrary well-formed XML as data input -
so I guess my validity parse can only be "partial". If I use a DTD,
I need to escape the arbitrary XML (hence the CDATA). I'm looking into
the "lax" option of XML Schemas in an attempt to avoid this.

Thanks for the pointer on saxon:parse() :)

Morten





 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]