Hi,
CDATA is used very rarely in XML documents. Its generally used when you have a lot of textual content like ">","<", "'", "&", """.
The use of CDATA is very rare as it rarely supports teh purpose for which xml was created!!!. (user defined tags). Data inside teh CDATA section is not parsed by teh parser.
So CDATA is generally used when you need to include non-xml data or a lot of pre-defined entities mentioned above.
Elemnts cannot have CDATA as their model. BUT Elemnts can have CDATA sections to store data as shown in the above example by lasse!!!
I guess thats y we also include our code segments in the
segment in javaranch so that the entire character set we type (along with white space) is preserved :-). It is not parsed by teh processor used to represent our documents. I guess CDATA is something similar to that !!!
hope this helps
hari