JSON与XML的另一个差异是属性的差别,由于JSON采取冒号赋值,这将导致当XML转化为JSON时,在标识符(XML CDATA)与实际属性值之间很难区分谁应当被当作文本斟酌。
基于28个网页-相关网页
XML CDATA sections contain raw text that should be included, but not parsed, with the XML that contains it.
XML CDATA 区段包含应该纳入、但不应剖析的未经处理文字,以及包含这段文字的 XML。
CDATA is the XML command that tells the viewer to stop parsing the code and read the code within the block that follows as character data.
CDATA是XML命令,它告诉查看程序停止解析代码,并读取接下来的块中的代码,这里的代码是字符数据的形式。
A better solution might be to put the data directly into your XML document. That's where XML's CDATA section comes into play.
更好的解决方案可能是将数据直接放到您的XML文档中,那就是XML的CDATA区域发挥作用的时候了。
应用推荐