{"id":538,"date":"2023-02-25T16:41:55","date_gmt":"2023-02-25T08:41:55","guid":{"rendered":"https:\/\/www.appblog.cn\/?p=538"},"modified":"2023-04-29T20:39:47","modified_gmt":"2023-04-29T12:39:47","slug":"using-curl-console-for-garbled-code-under-windows","status":"publish","type":"post","link":"https:\/\/www.appblog.cn\/index.php\/2023\/02\/25\/using-curl-console-for-garbled-code-under-windows\/","title":{"rendered":"Windows\u4e0b\u4f7f\u7528curl\u63a7\u5236\u53f0\u4e71\u7801\u95ee\u9898"},"content":{"rendered":"<p>\u4f7f\u7528Windows\u7248\u7684curl\uff0c\u5982<code>curl www.appblog.cn<\/code><\/p>\n<p>\u63a7\u5236\u53f0\u8f93\u51fa\u7684\u662f\u4e71\u7801<\/p>\n<p>\u89e3\u51b3\u529e\u6cd5\uff1a\u9700\u8981\u4e0b\u8f7diconv\uff1a<a target=\"_blank\" rel=\"noopener\" href=\"http:\/\/gnuwin32.sourceforge.NET\/packages\/libiconv.htm\">http:\/\/gnuwin32.sourceforge.NET\/packages\/libiconv.htm<\/a><\/p>\n<p><!-- more --><\/p>\n<p>\u5b89\u88c5exe\u6587\u4ef6\uff0c\u8bbe\u7f6e\u73af\u5883\u53d8\u91cf\uff0c\u5c06\u5b89\u88c5\u76ee\u5f55\u4e0b\u7684bin\u76ee\u5f55\u6dfb\u52a0\u5230path\u4e2d\uff0c\u6bd4\u5982\u6211\u7684\u662f<code>D:\\Program Files (x86)\\GnuWin32\\bin<\/code><\/p>\n<p>\u6700\u540e\u8f93\u5165\u547d\u4ee4<code>curl www.appblog.cn | iconv -f utf-8 -t gbk<\/code>\u5373\u53ef<\/p>\n<pre><code>D:\\&gt;curl http:\/\/127.0.0.1:8088\/api\/roles | iconv -f utf-8 -t gbk\n  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current\n                                 Dload  Upload   Total   Spent    Left  Speed\n100   113  100   113    0     0   3645      0 --:--:-- --:--:-- --:--:--  3645\n[{&quot;id&quot;:1,&quot;roleName&quot;:&quot;\u7ba1\u7406\u5458&quot;,&quot;created_at&quot;:&quot;2017-08-17T19:20:30.000Z&quot;,&quot;updated_at&quot;:&quot;2017-08-17T19:20:30.000Z&quot;}]<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u4f7f\u7528Windows\u7248\u7684curl\uff0c\u5982curl www.appblog.cn \u63a7\u5236\u53f0\u8f93\u51fa\u7684\u662f\u4e71\u7801 \u89e3\u51b3\u529e\u6cd5\uff1a\u9700\u8981\u4e0b [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[97],"tags":[73],"class_list":["post-538","post","type-post","status-publish","format-standard","hentry","category-tools-skills","tag-curl"],"_links":{"self":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/538","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/comments?post=538"}],"version-history":[{"count":0,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/538\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/media?parent=538"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/categories?post=538"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/tags?post=538"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}