{"id":998652,"date":"2024-12-27T09:34:57","date_gmt":"2024-12-27T01:34:57","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/998652.html"},"modified":"2024-12-27T09:35:12","modified_gmt":"2024-12-27T01:35:12","slug":"python%e5%a6%82%e4%bd%95%e4%bf%ae%e6%94%b9%e6%96%87%e5%ad%97%e9%a2%9c%e8%89%b2","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/998652.html","title":{"rendered":"python\u5982\u4f55\u4fee\u6539\u6587\u5b57\u989c\u8272"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25074012\/adc38bcd-1ae1-401d-a8a6-db37c57e3c34.webp\" alt=\"python\u5982\u4f55\u4fee\u6539\u6587\u5b57\u989c\u8272\" \/><\/p>\n<p><p> \u5728Python\u4e2d\u4fee\u6539\u6587\u5b57\u989c\u8272\u53ef\u4ee5\u901a\u8fc7\u591a\u4e2a\u65b9\u6cd5\u6765\u5b9e\u73b0\uff0c<strong>\u4f7f\u7528\u7ec8\u7aef\u989c\u8272\u4ee3\u7801\u3001\u5229\u7528\u7b2c\u4e09\u65b9\u5e93\u5982<code>colorama<\/code>\u3001\u5728GUI\u6846\u67b6\u4e2d\u4f7f\u7528\u7279\u5b9a\u7684\u5c5e\u6027\u6765\u4fee\u6539\u989c\u8272<\/strong>\u3002\u5176\u4e2d\uff0c\u4f7f\u7528\u7ec8\u7aef\u989c\u8272\u4ee3\u7801\u548c<code>colorama<\/code>\u5e93\u662f\u6700\u5e38\u89c1\u7684\u65b9\u6cd5\u3002\u63a5\u4e0b\u6765\uff0c\u6211\u5c06\u8be6\u7ec6\u4ecb\u7ecd\u5982\u4f55\u4f7f\u7528<code>colorama<\/code>\u5e93\u6765\u4fee\u6539\u7ec8\u7aef\u6587\u5b57\u989c\u8272\u3002<\/p>\n<\/p>\n<p><p><strong>\u4f7f\u7528Colorama\u5e93\u4fee\u6539\u7ec8\u7aef\u6587\u5b57\u989c\u8272<\/strong><\/p>\n<\/p>\n<p><p><code>Colorama<\/code>\u662f\u4e00\u4e2a\u53ef\u4ee5\u5728Windows\u548c\u5176\u4ed6\u64cd\u4f5c\u7cfb\u7edf\u4e2d\u4f7f\u7528\u7684\u5e93\uff0c\u5b83\u80fd\u591f\u5728\u7ec8\u7aef\u4e2d\u7b80\u5355\u5730\u6539\u53d8\u6587\u5b57\u7684\u989c\u8272\u3002\u9996\u5148\uff0c\u4f60\u9700\u8981\u5b89\u88c5<code>colorama<\/code>\u5e93\uff0c\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u547d\u4ee4\u5b89\u88c5\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install colorama<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5b89\u88c5\u5b8c\u6210\u540e\uff0c\u4f60\u53ef\u4ee5\u5728Python\u811a\u672c\u4e2d\u4f7f\u7528\u5b83\u6765\u6539\u53d8\u6587\u5b57\u989c\u8272\u3002\u4e0b\u9762\u662f\u4e00\u4e2a\u7b80\u5355\u7684\u4f8b\u5b50\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from colorama import init, Fore, Back, Style<\/p>\n<h2><strong>Initialize colorama<\/strong><\/h2>\n<p>init(autoreset=True)<\/p>\n<p>print(Fore.RED + &#39;This text is red&#39;)<\/p>\n<p>print(Fore.GREEN + &#39;This text is green&#39;)<\/p>\n<p>print(Back.BLUE + &#39;This text has a blue background&#39;)<\/p>\n<p>print(Style.DIM + &#39;This text is dim&#39;)<\/p>\n<p>print(Style.BRIGHT + &#39;This text is bright&#39;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u8fd9\u4e2a\u4f8b\u5b50\u4e2d\uff0c<code>init(autoreset=True)<\/code>\u7528\u4e8e\u521d\u59cb\u5316<code>colorama<\/code>\uff0c\u5e76\u786e\u4fdd\u989c\u8272\u4ee3\u7801\u5728\u6bcf\u6b21\u6253\u5370\u4e4b\u540e\u81ea\u52a8\u590d\u4f4d\uff0c\u8fd9\u6837\u540e\u7eed\u7684\u6587\u672c\u4e0d\u4f1a\u53d7\u5230\u524d\u9762\u8bbe\u7f6e\u7684\u989c\u8272\u5f71\u54cd\u3002<code>Fore<\/code>\u6a21\u5757\u7528\u4e8e\u8bbe\u7f6e\u524d\u666f\u8272\uff0c<code>Back<\/code>\u6a21\u5757\u7528\u4e8e\u8bbe\u7f6e\u80cc\u666f\u8272\uff0c<code>Style<\/code>\u6a21\u5757\u7528\u4e8e\u8bbe\u7f6e\u6587\u672c\u6837\u5f0f\u3002<\/p>\n<\/p>\n<p><p>\u63a5\u4e0b\u6765\uff0c\u6211\u5c06\u8be6\u7ec6\u4ecb\u7ecdPython\u4e2d\u4fee\u6539\u6587\u5b57\u989c\u8272\u7684\u5176\u4ed6\u65b9\u6cd5\u3002<\/p>\n<\/p>\n<p><p>\u4e00\u3001\u4f7f\u7528\u7ec8\u7aef\u989c\u8272\u4ee3\u7801<\/p>\n<\/p>\n<p><p>\u5728\u8bb8\u591a\u7ec8\u7aef\u4e2d\uff0c\u4f60\u53ef\u4ee5\u901a\u8fc7ANSI\u8f6c\u4e49\u5e8f\u5217\u6765\u6539\u53d8\u6587\u5b57\u989c\u8272\u3002\u8fd9\u4e9b\u5e8f\u5217\u662f\u4ee5<code>\\033[<\/code>\u5f00\u5934\u7684\u5b57\u7b26\u4e32\uff0c\u540e\u9762\u8ddf\u7740\u989c\u8272\u4ee3\u7801\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">print(&quot;\\033[31mThis is red text\\033[0m&quot;)<\/p>\n<p>print(&quot;\\033[32mThis is green text\\033[0m&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u8fd9\u91cc\uff0c<code>\\033[31m<\/code>\u662f\u5f00\u59cb\u7ea2\u8272\u6587\u672c\u7684\u4ee3\u7801\uff0c<code>\\033[0m<\/code>\u7528\u4e8e\u91cd\u7f6e\u989c\u8272\u3002\u8fd9\u79cd\u65b9\u6cd5\u7b80\u5355\u6709\u6548\uff0c\u4f46\u5728\u67d0\u4e9bWindows\u7ec8\u7aef\u4e2d\u53ef\u80fd\u4e0d\u652f\u6301\u3002<\/p>\n<\/p>\n<p><p><strong>\u989c\u8272\u4ee3\u7801\u8868<\/strong><\/p>\n<\/p>\n<ul>\n<li><code>30-37<\/code>\uff1a\u8bbe\u7f6e\u524d\u666f\u8272\uff08\u9ed1\u3001\u7ea2\u3001\u7eff\u3001\u9ec4\u3001\u84dd\u3001\u7d2b\u3001\u9752\u3001\u767d\uff09<\/li>\n<li><code>40-47<\/code>\uff1a\u8bbe\u7f6e\u80cc\u666f\u8272<\/li>\n<li><code>0<\/code>\uff1a\u91cd\u7f6e\u6240\u6709\u5c5e\u6027<\/li>\n<\/ul>\n<p><p>\u4e8c\u3001\u5728GUI\u6846\u67b6\u4e2d\u4fee\u6539\u6587\u5b57\u989c\u8272<\/p>\n<\/p>\n<p><p>\u5982\u679c\u4f60\u6b63\u5728\u5f00\u53d1\u4e00\u4e2a\u56fe\u5f62\u7528\u6237\u754c\u9762\uff08GUI\uff09\u5e94\u7528\u7a0b\u5e8f\uff0c\u8bb8\u591aGUI\u6846\u67b6\u90fd\u63d0\u4f9b\u4e86\u8bbe\u7f6e\u6587\u672c\u989c\u8272\u7684\u529f\u80fd\u3002\u4ee5\u4e0b\u662f\u4e00\u4e9b\u5e38\u89c1\u7684Python GUI\u6846\u67b6\u5982\u4f55\u8bbe\u7f6e\u6587\u672c\u989c\u8272\u7684\u4f8b\u5b50\uff1a<\/p>\n<\/p>\n<p><p><strong>Tkinter<\/strong><\/p>\n<\/p>\n<p><p>Tkinter\u662fPython\u7684\u6807\u51c6GUI\u5e93\u3002\u4f60\u53ef\u4ee5\u4f7f\u7528<code>fg<\/code>\u53c2\u6570\u6765\u8bbe\u7f6e\u524d\u666f\u8272\uff0c<code>bg<\/code>\u53c2\u6570\u6765\u8bbe\u7f6e\u80cc\u666f\u8272\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import tkinter as tk<\/p>\n<p>root = tk.Tk()<\/p>\n<p>label = tk.Label(root, text=&quot;Hello, World!&quot;, fg=&quot;red&quot;, bg=&quot;yellow&quot;)<\/p>\n<p>label.pack()<\/p>\n<p>root.m<a href=\"https:\/\/docs.pingcode.com\/blog\/59162.html\" target=\"_blank\">AI<\/a>nloop()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p><strong>PyQt<\/strong><\/p>\n<\/p>\n<p><p>PyQt\u662fPython\u7684\u53e6\u4e00\u4e2a\u6d41\u884c\u7684GUI\u5e93\u3002\u4f60\u53ef\u4ee5\u4f7f\u7528<code>setStyleSheet<\/code>\u65b9\u6cd5\u6765\u6539\u53d8\u6587\u672c\u989c\u8272\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from PyQt5 import QtWidgets<\/p>\n<p>app = QtWidgets.QApplication([])<\/p>\n<p>label = QtWidgets.QLabel(&#39;Hello, World!&#39;)<\/p>\n<p>label.setStyleSheet(&#39;color: red; background-color: yellow&#39;)<\/p>\n<p>label.show()<\/p>\n<p>app.exec_()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e09\u3001\u4f7f\u7528\u5176\u4ed6\u7b2c\u4e09\u65b9\u5e93<\/p>\n<\/p>\n<p><p>\u9664\u4e86<code>colorama<\/code>\uff0c\u8fd8\u6709\u5176\u4ed6\u7b2c\u4e09\u65b9\u5e93\u53ef\u4ee5\u7528\u4e8e\u6539\u53d8\u7ec8\u7aef\u4e2d\u7684\u6587\u5b57\u989c\u8272\u3002\u4f8b\u5982\uff1a<\/p>\n<\/p>\n<p><p><strong>Termcolor<\/strong><\/p>\n<\/p>\n<p><p><code>termcolor<\/code>\u662f\u53e6\u4e00\u4e2a\u7528\u4e8e\u5728\u7ec8\u7aef\u4e2d\u683c\u5f0f\u5316\u6587\u672c\u7684\u5e93\u3002\u4e0e<code>colorama<\/code>\u76f8\u4f3c\uff0c\u4f60\u53ef\u4ee5\u4f7f\u7528\u5b83\u6765\u8bbe\u7f6e\u6587\u672c\u7684\u989c\u8272\u548c\u80cc\u666f\u8272\u3002\u9996\u5148\u5b89\u88c5\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install termcolor<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4f7f\u7528\u793a\u4f8b\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">from termcolor import colored<\/p>\n<p>print(colored(&#39;Hello, World!&#39;, &#39;red&#39;, &#39;on_yellow&#39;))<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u56db\u3001\u65e5\u5fd7\u8bb0\u5f55\u4e2d\u7684\u989c\u8272<\/p>\n<\/p>\n<p><p>\u5728\u67d0\u4e9b\u60c5\u51b5\u4e0b\uff0c\u4f60\u53ef\u80fd\u5e0c\u671b\u4e3a\u65e5\u5fd7\u8f93\u51fa\u6dfb\u52a0\u989c\u8272\u3002\u53ef\u4ee5\u901a\u8fc7\u81ea\u5b9a\u4e49<code>logging<\/code>\u6a21\u5757\u4e2d\u7684\u683c\u5f0f\u5316\u5668\u6765\u5b9e\u73b0\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import logging<\/p>\n<p>class ColoredFormatter(logging.Formatter):<\/p>\n<p>    COLORS = {<\/p>\n<p>        &#39;DEBUG&#39;: &#39;\\033[94m&#39;,<\/p>\n<p>        &#39;INFO&#39;: &#39;\\033[92m&#39;,<\/p>\n<p>        &#39;WARNING&#39;: &#39;\\033[93m&#39;,<\/p>\n<p>        &#39;ERROR&#39;: &#39;\\033[91m&#39;,<\/p>\n<p>        &#39;CRITICAL&#39;: &#39;\\033[95m&#39;<\/p>\n<p>    }<\/p>\n<p>    RESET = &#39;\\033[0m&#39;<\/p>\n<p>    def format(self, record):<\/p>\n<p>        msg = super().format(record)<\/p>\n<p>        return f&quot;{self.COLORS[record.levelname]}{msg}{self.RESET}&quot;<\/p>\n<p>logger = logging.getLogger()<\/p>\n<p>handler = logging.StreamHandler()<\/p>\n<p>handler.setFormatter(ColoredFormatter(&quot;%(levelname)s: %(message)s&quot;))<\/p>\n<p>logger.addHandler(handler)<\/p>\n<p>logger.error(&quot;This is an error message&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e94\u3001\u603b\u7ed3\u4e0e\u6700\u4f73\u5b9e\u8df5<\/p>\n<\/p>\n<p><p>\u5728Python\u4e2d\u4fee\u6539\u6587\u5b57\u989c\u8272\u6709\u591a\u79cd\u65b9\u6cd5\uff0c\u5404\u6709\u4f18\u52a3\u3002\u4f7f\u7528<code>colorama<\/code>\u548c<code>termcolor<\/code>\u5e93\u662f\u7b80\u5355\u4e14\u8de8\u5e73\u53f0\u7684\u89e3\u51b3\u65b9\u6848\uff0c\u9002\u5408\u5927\u591a\u6570\u60c5\u51b5\u4e0b\u7684\u7ec8\u7aef\u8f93\u51fa\u3002\u5bf9\u4e8eGUI\u5e94\u7528\uff0c\u4f7f\u7528\u6846\u67b6\u63d0\u4f9b\u7684\u65b9\u6cd5\u53ef\u4ee5\u5f88\u65b9\u4fbf\u5730\u5b9e\u73b0\u989c\u8272\u4fee\u6539\u3002\u65e0\u8bba\u91c7\u7528\u54ea\u79cd\u65b9\u6cd5\uff0c\u90fd\u5e94\u6ce8\u610f\u4ee3\u7801\u7684\u53ef\u8bfb\u6027\u548c\u8de8\u5e73\u53f0\u517c\u5bb9\u6027\u3002<\/p>\n<\/p>\n<p><p>\u5728\u5904\u7406\u65e5\u5fd7\u65f6\uff0c\u4f7f\u7528\u81ea\u5b9a\u4e49\u683c\u5f0f\u5316\u5668\u53ef\u4ee5\u66f4\u597d\u5730\u63a7\u5236\u8f93\u51fa\u7684\u989c\u8272\u548c\u6837\u5f0f\uff0c\u4ece\u800c\u63d0\u9ad8\u65e5\u5fd7\u4fe1\u606f\u7684\u53ef\u8bfb\u6027\u548c\u8c03\u8bd5\u6548\u7387\u3002<\/p>\n<\/p>\n<p><p>\u603b\u4e4b\uff0c\u7075\u6d3b\u8fd0\u7528\u8fd9\u4e9b\u65b9\u6cd5\uff0c\u53ef\u4ee5\u5e2e\u52a9\u4f60\u5728\u5f00\u53d1\u4e2d\u66f4\u6709\u6548\u5730\u4f20\u8fbe\u4fe1\u606f\uff0c\u63d0\u9ad8\u7528\u6237\u4f53\u9a8c\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5728Python\u4e2d\uff0c\u5982\u4f55\u5728\u7ec8\u7aef\u4e2d\u4fee\u6539\u6587\u5b57\u989c\u8272\uff1f<\/strong><br \/>\u5728\u7ec8\u7aef\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528ANSI\u8f6c\u4e49\u5e8f\u5217\u6765\u4fee\u6539\u6587\u5b57\u989c\u8272\u3002\u901a\u8fc7\u5728\u8f93\u51fa\u7684\u5b57\u7b26\u4e32\u524d\u6dfb\u52a0\u7279\u5b9a\u7684\u8f6c\u4e49\u5e8f\u5217\uff0c\u53ef\u4ee5\u5b9e\u73b0\u5b57\u4f53\u989c\u8272\u7684\u53d8\u5316\u3002\u4f8b\u5982\uff0c\u4f7f\u7528 <code>\\033[31m<\/code> \u53ef\u4ee5\u5c06\u6587\u5b57\u53d8\u4e3a\u7ea2\u8272\uff0c\u800c <code>\\033[0m<\/code> \u5219\u7528\u4e8e\u91cd\u7f6e\u989c\u8272\u3002\u4ee5\u4e0b\u662f\u4e00\u4e2a\u7b80\u5355\u7684\u793a\u4f8b\u4ee3\u7801\uff1a<\/p>\n<pre><code class=\"language-python\">print(&quot;\\033[31m\u8fd9\u662f\u7ea2\u8272\u6587\u5b57\\033[0m&quot;)\n<\/code><\/pre>\n<p><strong>\u662f\u5426\u53ef\u4ee5\u5728Python GUI\u5e94\u7528\u4e2d\u6539\u53d8\u6587\u5b57\u989c\u8272\uff1f<\/strong><br \/>\u5f53\u7136\u53ef\u4ee5\u3002\u5728\u4f7f\u7528Tkinter\u6216\u5176\u4ed6GUI\u5e93\u65f6\uff0c\u53ef\u4ee5\u901a\u8fc7\u8bbe\u7f6e\u5b57\u4f53\u989c\u8272\u5c5e\u6027\u6765\u6539\u53d8\u6587\u5b57\u989c\u8272\u3002\u4f8b\u5982\uff0c\u5728Tkinter\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528 <code>fg<\/code> \u53c2\u6570\u6765\u8bbe\u7f6eLabel\u6216Button\u7684\u6587\u5b57\u989c\u8272\uff1a<\/p>\n<pre><code class=\"language-python\">import tkinter as tk\n\nroot = tk.Tk()\nlabel = tk.Label(root, text=&quot;\u8fd9\u662f\u84dd\u8272\u6587\u5b57&quot;, fg=&quot;blue&quot;)\nlabel.pack()\nroot.mainloop()\n<\/code><\/pre>\n<p><strong>\u5728Python\u4e2d\uff0c\u5982\u4f55\u5728\u7f51\u9875\u4e0a\u4fee\u6539\u6587\u5b57\u989c\u8272\uff1f<\/strong><br \/>\u5982\u679c\u4f60\u5728\u4f7f\u7528Flask\u6216Django\u7b49\u6846\u67b6\u5f00\u53d1\u7f51\u9875\uff0c\u53ef\u4ee5\u901a\u8fc7HTML\u548cCSS\u6765\u6539\u53d8\u6587\u5b57\u989c\u8272\u3002\u5728HTML\u4e2d\uff0c\u53ef\u4ee5\u76f4\u63a5\u4f7f\u7528 <code>style<\/code> \u5c5e\u6027\u6216\u901a\u8fc7CSS\u7c7b\u6765\u5b9e\u73b0\u3002\u4f8b\u5982\uff1a<\/p>\n<pre><code class=\"language-html\">&lt;p style=&quot;color: red;&quot;&gt;\u8fd9\u662f\u7ea2\u8272\u6587\u5b57&lt;\/p&gt;\n<\/code><\/pre>\n<p>\u6216\u8005\u5728CSS\u6587\u4ef6\u4e2d\u5b9a\u4e49\uff1a<\/p>\n<pre><code class=\"language-css\">.red-text {\n    color: red;\n}\n<\/code><\/pre>\n<p>\u7136\u540e\u5728HTML\u4e2d\u4f7f\u7528\u8be5\u7c7b\uff1a<\/p>\n<pre><code class=\"language-html\">&lt;p class=&quot;red-text&quot;&gt;\u8fd9\u662f\u7ea2\u8272\u6587\u5b57&lt;\/p&gt;\n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"\u5728Python\u4e2d\u4fee\u6539\u6587\u5b57\u989c\u8272\u53ef\u4ee5\u901a\u8fc7\u591a\u4e2a\u65b9\u6cd5\u6765\u5b9e\u73b0\uff0c\u4f7f\u7528\u7ec8\u7aef\u989c\u8272\u4ee3\u7801\u3001\u5229\u7528\u7b2c\u4e09\u65b9\u5e93\u5982colorama\u3001\u5728GUI [&hellip;]","protected":false},"author":3,"featured_media":998688,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[37],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/998652"}],"collection":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/comments?post=998652"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/998652\/revisions"}],"predecessor-version":[{"id":998692,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/998652\/revisions\/998692"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/998688"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=998652"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=998652"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=998652"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}