当我尝试验证我的网站时,出现以下错误:
Text run is not in Unicode Normalization Form C
甲:什么意思?
B:我可以用 notepad++ 修复它吗?如何修复?
C:如果 B 不是,我如何使用免费工具(不是 Dreamweaver)解决这个问题?
最佳答案
What does it mean?
来自 W3C :
In Unicode it is possible to produce the same text with different sequences of characters. For example, take the Hungarian word világ. The fourth letter could be stored in memory as a precomposed U+00E1 LATIN SMALL LETTER A WITH ACUTE (a single character) or as a decomposed sequence of U+0061 LATIN SMALL LETTER A followed by U+0301 COMBINING ACUTE ACCENT (two characters).
világ = világ
The Unicode Standard allows either of these alternatives, but requires that both be treated as identical. To improve efficiency, an application will usually normalize text before performing searches or comparisons. Normalization, in this case, means converting the text to use all precomposed or all decomposed characters.
There are four normalization forms specified by the Unicode Standard: NFC, NFD, NFKC and NFKD. The C stands for (pre-)composed, and the D for decomposed. The K stands for compatibility. To improve interoperability, the W3C recommends the use of NFC normalized text on the Web.
除了“提高互操作性”之外,预合成文本通常看起来比分解文本更好。
How can I fix this with free tools
通过在您最喜欢的编程语言中使用相当于 Python 的 text = unicodedata.normalize('NFC', text)
的函数。
(或者,如果您不打算编写程序,您的问题应该移交给 super 用户或网站管理员。)
关于html - 文本运行不在 Unicode 规范化形式 C,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5465170/