Can I create an element with forward slash as part of the name

白昼怎懂夜的黑 提交于 2019-12-17 20:33:19

问题


Can i create an element with forward slash as part of the name?

<Data>
<DataRow>
<Orange/Apple> fruit </Orange/Apple>
</DataRow>
</Data>

seems invalid to me but just want to confirm.


回答1:


Can i create an element with forward slash as part of the name?

No, according to the grammar pulished on the W3.org website it is not a valid character in a name.

hexadecimal value 0x20 cannot be included in a name

0x20 is the space character and you will see that it is not on the list of valid NameChars. It is considered whitespace unless it is part of a value.



来源:https://stackoverflow.com/questions/15000160/can-i-create-an-element-with-forward-slash-as-part-of-the-name

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!