{"id":371,"date":"2004-11-10T18:00:18","date_gmt":"2004-11-10T10:00:18","guid":{"rendered":"http:\/\/blog.axqd.net\/?p=371"},"modified":"2004-11-10T18:00:18","modified_gmt":"2004-11-10T10:00:18","slug":"196-apache-utf-8-encoded-url-problem","status":"publish","type":"post","link":"https:\/\/blog.axqd.net\/?p=371","title":{"rendered":"196 Apache UTF-8 Encoded URL Problem"},"content":{"rendered":"<p>[\u73b0\u8c61\u63cf\u8ff0]<\/p>\n<p>\u5f53\u4f60\u5728IE\u7684\u6d4f\u89c8\u5668\u4e2d\u8f93\u5165URL\u5730\u5740\u7684\u65f6\u5019\uff0cIE\u4f1a\u4ee5UTF-8\u5bf9\u5176\u8fdb\u884c\u7f16\u7801\uff08\u9664\u975e\u5728\u9ad8\u7ea7\u8bbe\u7f6e\u91cc\u9762\u53d6\u6d88\u9009\u9879\u201c\u603b\u662f\u4ee5UTF-8\u53d1\u9001URL\u201d\uff09\uff0c\u7531\u6b64\uff0c\u5168\u9762\u652f\u6301\u56fd\u9645\u5316\u8bed\u8a00\u3002<br \/>\n\u4f46\u662f\u5bf9\u4e8e\u4e00\u822c\u914d\u7f6e\u7684apache\u670d\u52a1\u5668\uff0c\u9ed8\u8ba4\u5e76\u4e0d\u4f1a\u652f\u6301UTF-8\u7f16\u7801\u7684URL\uff0c\u56e0\u6b64\u5f53\u4f60\u53d1\u9001\u5305\u542b\u4e2d\u6587\u7684URL\uff08\u4f8b\u5982\uff1ahttp:\/\/***.***.***.***\/\u97f3\u4e50.***\uff09\u65f6\uff0c\u4f1a\u8fd4\u56de 404 Not Found \u9519\u8bef\u3002<br \/>\n\u4e00\u822c\u7684\u89e3\u51b3\u65b9\u6cd5\u662f\u5c06\u53d1\u9001URL\u8bf7\u6c42\u4e2d\u7684\u4e2d\u6587\u91c7\u7528URLEncode\uff08\uff09\u8fdb\u884c\u8f6c\u6362\uff0c\u5f62\u6210apache\u80fd\u591f\u652f\u6301\u7684URL\u683c\u5f0f\uff08\u4f8b\u5982\uff1ahttp:\/\/***.***.***.***\/%D2%F4%C0%D6.***\uff09\uff0c\u4f46\u662f\u8fd9\u6837\u89e3\u51b3\u7684\u95ee\u9898\u662f\uff0c\u5982\u679c\u4e0b\u8f7d\u7684\u662fmp3\u7684\u8bdd\uff0c\u4e0b\u8f7d\u94fe\u63a5\u4e2d\u5305\u542b\u4e71\u7801\uff0c\u53ef\u80fd\u4f1a\u5bfc\u81f4\u67d0\u4e9b\u64ad\u653e\u5668\u4e0d\u80fd\u6b63\u786e\u663e\u793a\u6b4c\u540d\uff0c\u8fdb\u800c\u5bfc\u81f4\u4e0d\u80fd\u6b63\u786e\u4f7f\u7528\u8ff7\u4f60\u6b4c\u8bcd\u3002<br \/>\n\u7efc\u4e0a\u6240\u8ff0\uff0c\u6700\u597d\u7684\u89e3\u51b3\u65b9\u6848\u662f\u4f7fapache\u652f\u6301\u76f4\u63a5\u5305\u542b\u4e2d\u6587\u7684URL\u3002<\/p>\n<p>[\u89e3\u51b3\u65b9\u6cd5]<\/p>\n<p>\u5bf9\u4e8e\u6b64\u95ee\u9898\uff0capache\u5b98\u65b9\u5e76\u6ca1\u6709\u53d1\u5e03\u76f8\u5e94\u7684\u89e3\u51b3\u65b9\u6848\uff0c\u4f46\u662f\u5728\u7f51\u4e0a\u5374\u4e8e\u5f88\u65e9\u4ee5\u524d\u5df2\u7ecf\u89e3\u51b3\u4e86\u6b64\u95ee\u9898\uff0c\u65b9\u6cd5\u662f\u4f7f\u7528\u7531\u7b2c\u4e09\u65b9\u53d1\u5e03\u7684\u4e00\u4e2a\u8f6c\u6362\u6a21\u5757\uff0c\u7c4d\u7531apache\u63d0\u4f9b\u7684\u7b2c\u4e09\u65b9\u6a21\u5757\u5b89\u88c5\u5de5\u5177apxs\u5b89\u88c5\u5373\u53ef\u3002\uff08ps\uff1a\u5176\u5b9e\u6b64\u6a21\u5757\u4ee3\u7801\u6781\u5c11\uff0c\u5c31\u662f\u505a\u4e2a\u8f6c\u6362\uff1aP\uff0c\u4e3b\u8981\u662f\u540capache\u7684\u63a5\u53e3\u7ed3\u5408\u6bd4\u8f83\u9ebb\u70e6\uff09\u5177\u4f53\u6b65\u9aa4\u63cf\u8ff0\u5982\u4e0b\uff1a<\/p>\n<p>1\u3001\u9996\u5148\u8981\u786e\u4fddapache\u670d\u52a1\u5668\u5728\u7f16\u8bd1\u7684\u65f6\u5019\u5b89\u88c5\u4e86apxs\uff0c\u5e76\u4e14configure\u7684\u65f6\u5019\u91c7\u7528\u4e86\u9009\u9879 &#8211;enable-so(apache 2.0)\u6216\u8005 &#8211;enable-module=so(apache 1.0) \uff08\u8bf7\u52a1\u5fc5\u6ce8\u610f\u7248\u672c\uff0c\u5982\u679c\u5199\u9519\uff0c\u63d0\u793a\u4e0d\u5bb9\u6613\u53d1\u73b0\uff0c\u6700\u7ec8\u4f1a\u5bfc\u81f4\u6ca1\u6cd5\u7f16\u5165\u6a21\u5757\uff09\u3002<br \/>\n\u91c7\u7528\u4ee5\u4e0a\u7f16\u8bd1\u9009\u9879\u4f1a\u4f7fapache\u652f\u6301\u7b2c\u4e09\u65b9\u63d2\u4ef6\u3002<br \/>\n\u53e6\u5916\uff0c\u5982\u679capche\u670d\u52a1\u5668\u662f\u4f7f\u7528\u7684\u5b89\u88c5\u7cfb\u7edf\u65f6\u5019\u81ea\u5e26\u7684\uff08\u4ee5RedHat 9.0\u4e3a\u4f8b\uff09\uff0c\u5219\u6ca1\u6709apxs\u8fd9\u4e2a\u8f6f\u4ef6\uff0c\u8bf7\u5148\u884c\u5b89\u88c5apache-devel\u8f6f\u4ef6\u5305\uff0c\u5e76\u4e14\u6b64\u8f6f\u4ef6\u5305\u7684\u7248\u672c\u52a1\u5fc5\u4e0e\u4f60apache\u670d\u52a1\u5668\u7684\u7248\u672c\u4e00\u81f4\u3002<\/p>\n<p>2\u3001\u4e0b\u8f7d\u5e76\u5b89\u88c5mod_utf8\u8f6f\u4ef6\u5305\uff08\u76ee\u524d\u7248\u672c1.3\uff09<br \/>\n\u6ce8\u610f\u9009\u5bf9apache1.*\u548capache2.*\uff0c\u7136\u540e\u6267\u884c\uff1a<br \/>\napxs -a -i -c mod_utf8.c<\/p>\n<p>3\u3001\u91cd\u542fapache\u670d\u52a1\u5668<\/p>\n<p>\u5f53\u7136\u5b9e\u9645\u64cd\u4f5c\u8fc7\u7a0b\u4e2d\uff0c\u53ef\u80fd\u4f1a\u9047\u5230\u5404\u79cd\u5404\u6837\u7684\u95ee\u9898\uff0c\u56e0\u4e3a\u8fd9\u4e2a\u8f6f\u4ef6\u5305\u8fd8\u5e76\u4e0d\u662f\u7279\u522b\u7684\u5b8c\u7f8e\uff0c\u56e0\u6b64\u9700\u8981\u5177\u5907\u4e00\u5b9a\u7684\u6392\u9519\u80fd\u529b\uff0c\u8f6f\u4ef6\u5305\u7531C\u8bed\u8a00\u4e66\u5199\uff0c\u4e0b\u8f7d\u6e90\u4ee3\u7801\uff0c<a href=\"https:\/\/blog.axqd.net\/wp-content\/uploads\/2008\/06\/mod_utf-8.c\">\u8bf7\u70b9\u51fb\u8fd9\u91cc<\/a>\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>[\u73b0\u8c61\u63cf\u8ff0] \u5f53\u4f60\u5728IE\u7684\u6d4f\u89c8\u5668\u4e2d\u8f93\u5165URL\u5730\u5740\u7684\u65f6\u5019\uff0cIE\u4f1a\u4ee5UTF-8\u5bf9\u5176\u8fdb\u884c\u7f16\u7801\uff08\u9664\u975e\u5728\u9ad8\u7ea7\u8bbe\u7f6e\u91cc\u9762\u53d6\u6d88 &hellip; <a href=\"https:\/\/blog.axqd.net\/?p=371\" class=\"more-link\">\u7ee7\u7eed\u9605\u8bfb<span class=\"screen-reader-text\">\u201c196 Apache UTF-8 Encoded URL Problem\u201d<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[10],"tags":[23,106,154],"class_list":["post-371","post","type-post","status-publish","format-standard","hentry","category-10","tag-apache","tag-netunion","tag-utf-8"],"_links":{"self":[{"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/posts\/371","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=371"}],"version-history":[{"count":0,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/posts\/371\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.axqd.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=371"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=371"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=371"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}