gpt4 book ai didi

xml - 什么时候需要在xml中使用“?

转载 作者:数据小太阳 更新时间:2023-10-29 01:40:13 27 4
gpt4 key购买 nike

当我有不在属性中的引号时,我是否需要使用 " 对它们进行编码?

哪个是正确的?附件 A 还是附件 B?

图表A

<boat>
<name> Bertha </name>
<description> Good boat. 10 feet long. "Fixer-upper"</description>
</boat>

图表 B

<boat>
<name> Bertha </name>
<description> Good boat. 10 feet long. &quot;Fixer-upper&quot;</description>
</boat>

最佳答案

你的两个例子都是有效的。

你只需要在属性值中使用"" 字符会提前关闭属性。

关于xml - 什么时候需要在xml中使用“?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5186179/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com