我看到许多网站(亚马逊、维基百科等)在其 URL 中使用 UTF8 编码、URL 转义的 unicode,并且这些 URL(至少)经过 Chrome 美化。
例如,我们将表示 http://ja.wikipedia.org/wiki/マインページ as http://ja.wikipedia.org/wiki/%E3%83%A1%E3%82%A4%E3%83%B3%E3%83%9A%E3%83%BC%E3%82%B8在编写我们的 http header 时,Chrome 和 Firefox 似乎以一种优雅的方式理解了这一点。 (我没有在 IE 上测试。)
是否有针对此行为的管理标准?还是严格意义上的事实标准?还是完全不规范?
我真的很想看到一些 RFC 的定义段落的链接。
最佳答案
When a new URI scheme defines a component that represents textual data consisting of characters from the Universal Character Set [UCS], the data should first be encoded as octets according to the UTF-8 character encoding [STD63]; then only those octets that do not correspond to characters in the unreserved set should be percent- encoded.
这似乎很明确。
我仍然不确定它何时被批准,或者当前的浏览器支持。
关于http - UTF8 +转义我们的国际网址是标准的吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9115297/