HTML5“扩展到C1控制范围的数字字符引用”使用“时出错 [英] HTML5 "A numeric character reference expanded to the C1 controls range" error when using “
问题描述
我有这个html代码:
i have this html code:
<span class="comma_left">“</span>
和
And
<span class="comma_right">”</span>
同样,代表left&正确的逗号。
As well, both representing left & right commas.
奇怪的是, HTML5验证抛出错误:
扩展到C1控制范围的数字字符引用。
我真的不想只是避免这个错误,我能做什么?
I really don't want to just avoid this error, what can i do?
推荐答案
C1控制范围是指映射到字节的字符在 Latin-1 中编码0x80至0x9f(128至159),或者转换为<一个href =http://www.unicode.org/charts/PDF/U0080.pdf =noreferrer> Unicode代码点U + 0080至U + 009F 。 Unicode认为这些是控制字符,它们明确地是不允许使用HTML5分析算法。
The C1 control range refers to characters mapped to byte encodings 0x80 to 0x9f (128 to 159) in Latin-1, or to Unicode code points U+0080 to U+009F. Unicode considers these to be "control characters", which are explicitly disallowed by the HTML5 parsing algorithm.
由于您使用 Windows代码页1252 指示编码,您的问题正在发生双引号,与拉丁-1和Unicode不兼容。您可以尝试这些兼容的变体:
Your problem is occurring because you're using the Windows code page 1252 encodings of directed double-quote marks, which are incompatible with both Latin-1 and Unicode. You could try these compatible variants:
- 左双引号:
& ldquo;
或&#8220;
- 右侧双引号:
& rdquo;
或&#8221;
- Left double-quote:
“
or“
- Right double-quote:
”
or”
这篇关于HTML5“扩展到C1控制范围的数字字符引用”使用&#147;时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!