{"id":325132,"date":"2022-11-19T14:29:54","date_gmt":"2022-11-19T06:29:54","guid":{"rendered":"https:\/\/www.idc.net\/help\/325132\/"},"modified":"2022-11-19T14:29:54","modified_gmt":"2022-11-19T06:29:54","slug":"%e4%b8%ba%e4%bb%80%e4%b9%88%e5%8f%aa%e6%9c%89unicode%e6%98%af%e4%b8%8d%e5%a4%9f%e7%9a%84%ef%bc%8cutf-8%e5%a6%82%e4%bd%95%e8%a7%a3%e5%86%b3%e7%bc%96%e7%a0%81%e9%97%ae%e9%a2%98","status":"publish","type":"post","link":"https:\/\/idc.net\/help\/325132\/","title":{"rendered":"\u4e3a\u4ec0\u4e48\u53ea\u6709Unicode\u662f\u4e0d\u591f\u7684\uff0cUTF-8\u5982\u4f55\u89e3\u51b3\u7f16\u7801\u95ee\u9898?"},"content":{"rendered":"<h3>Unicode<\/h3>\n<p>Unicode\u662f\u4e00\u79cd\u5b57\u7b26\u7f16\u7801\u6807\u51c6\uff0c\u5b83\u4e3a\u4e16\u754c\u4e0a\u51e0\u4e4e\u6240\u6709\u7684\u6587\u5b57\u548c\u7b26\u53f7\u5206\u914d\u4e86\u552f\u4e00\u7684\u6570\u5b57\u7f16\u7801\u3002\u8fd9\u4f7f\u5f97\u4e0d\u540c\u7684\u8ba1\u7b97\u673a\u7cfb\u7edf\u548c\u8f6f\u4ef6\u80fd\u591f\u6b63\u786e\u5730\u663e\u793a\u548c\u5904\u7406\u5404\u79cd\u8bed\u8a00\u7684\u6587\u5b57\u3002Unicode\u91c7\u752816\u4f4d\u621632\u4f4d\u7f16\u7801\uff0c\u53ef\u4ee5\u8868\u793a\u8d85\u8fc7130\u4e07\u4e2a\u5b57\u7b26\u3002<\/p>\n<p>\u300c\u4e3a\u4ec0\u4e48\u53ea\u6709Unicode\u662f\u4e0d\u591f\u7684\u300d<\/p>\n<ol>\n<li>\u300c\u7f16\u7801\u957f\u5ea6\u4e0d\u4e00\u81f4\u300d\uff1a\u5728Unicode\u4e2d\uff0c\u5b57\u7b26\u7684\u7f16\u7801\u957f\u5ea6\u53ef\u4ee5\u662f1\u4e2a\u5b57\u8282\u30012\u4e2a\u5b57\u8282\u30013\u4e2a\u5b57\u8282\u62164\u4e2a\u5b57\u8282\uff0c\u8fd9\u4f7f\u5f97\u5728\u5b58\u50a8\u548c\u4f20\u8f93\u65f6\u9700\u8981\u8003\u8651\u7f16\u7801\u957f\u5ea6\u7684\u4e0d\u4e00\u81f4\u6027\u3002<\/li>\n<li>\u300c\u5b58\u50a8\u548c\u4f20\u8f93\u6548\u7387\u300d\uff1a\u7531\u4e8eUnicode\u5b57\u7b26\u96c6\u975e\u5e38\u5e9e\u5927\uff0c\u4f7f\u7528Unicode\u7f16\u7801\u53ef\u80fd\u4f1a\u5bfc\u81f4\u5b58\u50a8\u548c\u4f20\u8f93\u6548\u7387\u4f4e\u4e0b\uff0c\u7279\u522b\u662f\u5bf9\u4e8e\u53ea\u5305\u542b\u5c11\u91cf\u5b57\u7b26\u7684\u6587\u672c\u800c\u8a00\u3002<\/li>\n<li>\u300c\u517c\u5bb9\u6027\u300d\uff1a\u8bb8\u591a\u73b0\u6709\u7684\u7cfb\u7edf\u548c\u8f6f\u4ef6\u53ef\u80fd\u4ecd\u7136\u4f7f\u7528\u5176\u4ed6\u7f16\u7801\u65b9\u5f0f\uff0c\u5982ASCII\u3001ISO-8859\u7b49\uff0c\u56e0\u6b64\u9700\u8981\u4e0e\u8fd9\u4e9b\u7f16\u7801\u65b9\u5f0f\u8fdb\u884c\u517c\u5bb9\u3002<\/li>\n<\/ol>\n<p>\u4e3e\u4e2a\u4f8b\u5b50\uff0c\u5047\u5982\u6211\u4eec\u81ea\u5df1\u4e3a\u5b57\u7b26\u7f16\u7801\uff0c\u7f16\u7801\u89c4\u5219\u5982\u4e0b\uff1a<\/p>\n<pre><code>a -- 1\nb -- 2\nc -- 3\n...\nz -- 26<\/code><\/pre>\n<p>\u5982\u679c\u7528\u4e0a\u9762\u7684\u7f16\u7801\u8868\u793aadd\uff0c\u7ed3\u679c\u5c31\u662f144\u3002\u800c\u5f53\u6211\u4eec\u8981\u8868\u793ahello\u65f6\u6ca1\u7ed3\u679c\u5c31\u662f85121215\u3002\u6b64\u65f685121215\u8fd8\u53ef\u4ee5\u8868\u793a\u4e3aheababo\u3001heababae\u3001heablo\u7b49\uff0c\u6b64\u65f6\u8fd9\u4e2a\u7f16\u7801\u7ed3\u679c\u5c31\u4e0d\u6b63\u786e\u4e86\u3002<\/p>\n<p style=\"text-align:center\"><span>\u56fe\u7247<\/span><\/p>\n<p>\u6b64\u65f6\u768412\u548c15\u5c31\u53ef\u4ee5\u8868\u793a\u4e3a\u4e0d\u540c\u7684\u7ec4\u5408\uff0c\u8fd9\u5c31\u4f1a\u5bfc\u81f4\u7ed3\u679c\u5dee\u5f02\u3002\u8fd9\u91cc\u4ec5\u4ec5\u53ea\u662f\u8868\u793a\u4e8626\u4e2a\u5b57\u6bcd\uff0c\u518d\u52a0\u5165\u5176\u4ed6\u5b57\u7b26\u7684\u60c5\u51b5\u4e0bUnicode\u8fdc\u8fdc\u662f\u4e0d\u591f\u7684\u3002<\/p>\n<p>\u6211\u4eec\u770b\u770bUTF-8\u5982\u4f55\u89e3\u51b3\u4e0a\u9762\u7684\u7f16\u7801\u95ee\u9898\uff0c\u6b64\u65f6\u6709\u4e24\u79cd\u601d\u8def\uff1a<\/p>\n<ol>\n<li>\u7b2c\u4e00\u79cd\u662f\u56fa\u5b9a\u4f4d\u6570\u89e3\u6790\uff1a\u5982\u56fa\u5b9a\u4e24\u4f4d\u89e3\u6790\uff0c\u4e0d\u8db3\u7684\u88650\u3002\u8fd9\u65f6 hello\u7684\u7f16\u7801\u7ed3\u679c\u5c31\u4e3a0805121215\u3002<\/li>\n<li>\u7b2c\u4e8c\u79cd\u662f\u589e\u52a0\u6807\u5fd7\u4f4d\uff1a\u5982\u6700\u7b80\u5355\u7684\u52a0\u7a7a\u683c\uff0c\u8fd9\u65f6hello\u7684\u7f16\u7801\u5c31\u662f8 5 12 12 15\u3002<\/li>\n<\/ol>\n<p>\u5728Unicode\u4e2d\uff0c\u89e3\u51b3\u65b9\u6848\u53ebUTF(Unicode transformation format)\uff0c\u6709\u4e09\u79cd\u7f16\u7801\u65b9\u5f0f\u5206\u522b\u662fUTF-8\u3001UTF-16\u3001UTF-32\u3002UTF-32\u662f\u7b2c\u4e00\u79cd\u601d\u8def\uff0c\u56fa\u5b9a32\u4f4d\u89e3\u6790\uff0c\u4e0d\u8db3\u88650\uff1bUTF-8\u3001UTF-16\u5219\u662f\u7b2c\u4e8c\u79cd\u601d\u8def\u3002<\/p>\n<h3>UTF-8<\/h3>\n<p>UTF-8\uff088-bit Unicode Transformation Format\uff09\u662f\u4e00\u79cd\u9488\u5bf9Unicode\u7684\u53ef\u53d8\u957f\u5ea6\u5b57\u7b26\u7f16\u7801\uff0c\u5b83\u53ef\u4ee5\u7528\u6765\u8868\u793a\u4e16\u754c\u4e0a\u51e0\u4e4e\u6240\u6709\u7684\u5b57\u7b26\u3002\u5728UTF-8\u7f16\u7801\u4e2d\uff0c\u6bcf\u4e2a\u5b57\u7b26\u7684\u7f16\u7801\u957f\u5ea6\u53ef\u4ee5\u662f1\u4e2a\u5b57\u8282\u30012\u4e2a\u5b57\u8282\u30013\u4e2a\u5b57\u8282\u62164\u4e2a\u5b57\u8282\uff0c\u8fd9\u4f7f\u5f97UTF-8\u7f16\u7801\u975e\u5e38\u7075\u6d3b\uff0c\u53ef\u4ee5\u8282\u7701\u5b58\u50a8\u7a7a\u95f4\u3002UTF-8\u7f16\u7801\u901a\u8fc7\u7075\u6d3b\u7684\u5b57\u8282\u957f\u5ea6\u6765\u8868\u793aUnicode\u5b57\u7b26\uff0c\u4f7f\u5f97\u5b83\u6210\u4e3a\u4e00\u79cd\u5e7f\u6cdb\u5e94\u7528\u7684\u5b57\u7b26\u7f16\u7801\u65b9\u5f0f\u3002<\/p>\n<p>UTF-8\u7f16\u7801\u7684\u7279\u70b9\uff1a<\/p>\n<ul>\n<li>\u5bf9\u4e8e\u82f1\u6587\u5b57\u7b26\uff0c\u4f7f\u75281\u4e2a\u5b57\u8282\u8868\u793a\uff0c\u4e0eASCII\u517c\u5bb9\uff1b<\/li>\n<li>\u5bf9\u4e8e\u5e38\u89c1\u7684\u5176\u4ed6\u8bed\u8a00\uff08\u5982\u897f\u6b27\u8bed\u8a00\u3001\u4e2d\u6587\u3001\u65e5\u6587\u7b49\uff09\u7684\u5b57\u7b26\uff0c\u4f7f\u75282\u4e2a\u62163\u4e2a\u5b57\u8282\u8868\u793a\uff1b<\/li>\n<li>\u5bf9\u4e8e\u8f83\u5c11\u4f7f\u7528\u7684\u5b57\u7b26\uff0c\u4f7f\u75284\u4e2a\u5b57\u8282\u8868\u793a\u3002<\/li>\n<\/ul>\n<p>UTF-8\u4f7f\u75281\u81f34\u4e2a\u5b57\u8282\u6765\u8868\u793a\u4e00\u4e2a\u5b57\u7b26\u3002\u5176\u7f16\u7801\u89c4\u5219\u5982\u4e0b\uff1a<\/p>\n<p style=\"text-align:center\"><span>\u56fe\u7247<\/span><\/p>\n<ul>\n<li>\u5bf9\u4e8e\u5355\u5b57\u8282\u5b57\u7b26\uff08\u5373ASCII\u5b57\u7b26\uff09\uff0cUTF-8\u7f16\u7801\u548cASCII\u7f16\u7801\u662f\u76f8\u540c\u7684\u3002<\/li>\n<li>\u5bf9\u4e8e\u591a\u5b57\u8282\u5b57\u7b26\uff0cUTF-8\u4f7f\u7528\u4e0d\u540c\u7684\u5b57\u8282\u5e8f\u5217\u6765\u8868\u793a\u4e0d\u540c\u7684Unicode\u7801\u4f4d\u3002\u5177\u4f53\u89c4\u5219\u5982\u4e0b\uff1a<\/li>\n<\/ul>\n<ul>\n<li>\u5bf9\u4e8e\u7801\u4f4d\u5728U+0000\u81f3U+007F\u8303\u56f4\u5185\u7684\u5b57\u7b26\uff0c\u4f7f\u7528\u4e00\u4e2a\u5b57\u8282\u8868\u793a\uff0c\u6700\u9ad8\u4f4d\u4e3a0\u3002<\/li>\n<li>\u5bf9\u4e8e\u7801\u4f4d\u5728U+0080\u81f3U+07FF\u8303\u56f4\u5185\u7684\u5b57\u7b26\uff0c\u4f7f\u7528\u4e24\u4e2a\u5b57\u8282\u8868\u793a\uff0c\u6700\u9ad8\u4e09\u4f4d\u4e3a110\u3002<\/li>\n<li>\u5bf9\u4e8e\u7801\u4f4d\u5728U+0800\u81f3U+FFFF\u8303\u56f4\u5185\u7684\u5b57\u7b26\uff0c\u4f7f\u7528\u4e09\u4e2a\u5b57\u8282\u8868\u793a\uff0c\u6700\u9ad8\u56db\u4f4d\u4e3a1110\u3002<\/li>\n<li>\u5bf9\u4e8e\u7801\u4f4d\u5728U+10000\u81f3U+10FFFF\u8303\u56f4\u5185\u7684\u5b57\u7b26\uff0c\u4f7f\u7528\u56db\u4e2a\u5b57\u8282\u8868\u793a\uff0c\u6700\u9ad8\u4e94\u4f4d\u4e3a11110\u3002<\/li>\n<\/ul>\n<p>\u8fd9\u79cd\u7f16\u7801\u65b9\u5f0f\u4fdd\u8bc1\u4e86\u5bf9\u4e8e\u4e0d\u540c\u8303\u56f4\u7684Unicode\u5b57\u7b26\uff0cUTF-8\u7f16\u7801\u7684\u5b57\u8282\u6570\u662f\u4e0d\u540c\u7684\uff0c\u4ece\u800c\u5b9e\u73b0\u4e86\u5bf9Unicode\u5b57\u7b26\u96c6\u7684\u9ad8\u6548\u7f16\u7801\u548c\u517c\u5bb9\u6027\u3002<\/p>\n<p>\u6211\u4eec\u7528\u6c49\u8fd9\u4e2a\u5b57\u4e3a\u4f8b\uff1a<\/p>\n<pre><code>**\u6c49**\u7684 Unicode \u7f16\u7801\u4e3a:U+6C49\n**\u6c49**\u5bf9\u5e94\u7684\u4e8c\u8fdb\u5236\u4e3a:01101100 01001001<\/code><\/pre>\n<p>\u6c49\u7684Unicode\u4e3aU+6C49\uff0c\u6240\u4ee5\u5bf9\u5e94\u89c4\u5219\u591a\u5b57\u8282\u4e2d\u7684\u4e09\u4e2a\u5b57\u8282\uff0c\u6b64\u65f6\u7f16\u7801\u89c4\u5219\u4e3a1110xxxx 10xxxxxx 10xxxxxx\u3002<\/p>\n<p style=\"text-align:center\"><span>\u56fe\u7247<\/span><\/p>\n<p>\u5c06\u5bf9\u7528\u7684\u4e8c\u8fdb\u5236\u5e26\u5165\u7f16\u7801\u89c4\u5219\u4e2d\u5f97\u5230\u7f16\u7801\u4e3a:11100110 10110001 10001001\u3002<\/p>\n<h3>\u603b\u7ed3<\/h3>\n<p>Unicode\u662f\u4e00\u79cd\u5b57\u7b26\u96c6\uff0c\u5b83\u4e3a\u4e16\u754c\u4e0a\u51e0\u4e4e\u6240\u6709\u7684\u5b57\u7b26\u5206\u914d\u4e86\u4e00\u4e2a\u552f\u4e00\u7684\u6807\u8bc6\u7b26\uff0c\u4ee5\u4fbf\u8ba1\u7b97\u673a\u53ef\u4ee5\u7406\u89e3\u548c\u5904\u7406\u5404\u79cd\u8bed\u8a00\u7684\u6587\u672c\u3002Unicode\u7684\u76ee\u6807\u662f\u4e3a\u5168\u7403\u8303\u56f4\u5185\u7684\u6bcf\u4e2a\u5b57\u7b26\u63d0\u4f9b\u4e00\u4e2a\u552f\u4e00\u7684\u6807\u8bc6\u7b26\u3002<\/p>\n<p>UTF-8\u662f\u4e00\u79cdUnicode\u7684\u5b9e\u73b0\u65b9\u5f0f\uff0c\u5b83\u662f\u4e00\u79cd\u53ef\u53d8\u957f\u5ea6\u7684\u5b57\u7b26\u7f16\u7801\u65b9\u5f0f\uff0c\u53ef\u4ee5\u7528\u6765\u8868\u793aUnicode\u6807\u51c6\u4e2d\u7684\u5b57\u7b26\u3002UTF-8\u7f16\u7801\u4f7f\u75281\u52304\u4e2a\u5b57\u8282\u6765\u8868\u793a\u4e00\u4e2a\u5b57\u7b26\uff0c\u6839\u636e\u5b57\u7b26\u7684\u4e0d\u540c\u8303\u56f4\u6765\u786e\u5b9a\u4f7f\u7528\u7684\u5b57\u8282\u6570\uff0c\u8fd9\u6837\u53ef\u4ee5\u8282\u7701\u5b58\u50a8\u7a7a\u95f4\u5e76\u63d0\u9ad8\u4f20\u8f93\u6548\u7387\u3002<\/p>\n<p>Unicode\u7684\u63d0\u51fa\u89e3\u51b3\u4e86\u4f20\u7edf\u5b57\u7b26\u7f16\u7801\u65b9\u6848\u7684\u5c40\u9650\u6027\uff0c\u4f7f\u5f97\u8ba1\u7b97\u673a\u53ef\u4ee5\u66f4\u597d\u5730\u5904\u7406\u5168\u7403\u8303\u56f4\u5185\u7684\u591a\u8bed\u8a00\u6587\u672c\u3002\u800cUTF-8\u4f5c\u4e3aUnicode\u7684\u4e00\u79cd\u5b9e\u73b0\u65b9\u5f0f\uff0c\u4e3a\u6587\u672c\u7684\u5b58\u50a8\u548c\u4f20\u8f93\u63d0\u4f9b\u4e86\u9ad8\u6548\u7684\u89e3\u51b3\u65b9\u6848\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Unicode Unicode\u662f\u4e00\u79cd\u5b57\u7b26\u7f16\u7801\u6807\u51c6\uff0c\u5b83\u4e3a\u4e16\u754c\u4e0a\u51e0\u4e4e\u6240\u6709\u7684\u6587\u5b57\u548c\u7b26\u53f7\u5206\u914d\u4e86\u552f\u4e00\u7684\u6570\u5b57\u7f16\u7801\u3002\u8fd9\u4f7f\u5f97\u4e0d [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":325133,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[61],"tags":[],"class_list":["post-325132","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-website"],"_links":{"self":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/posts\/325132","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/comments?post=325132"}],"version-history":[{"count":0,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/posts\/325132\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/media\/325133"}],"wp:attachment":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/media?parent=325132"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/categories?post=325132"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/tags?post=325132"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}