{"id":20740,"date":"2024-11-19T12:55:14","date_gmt":"2024-11-19T04:55:14","guid":{"rendered":"https:\/\/fwq.ai\/blog\/20740\/"},"modified":"2024-11-19T12:55:14","modified_gmt":"2024-11-19T04:55:14","slug":"sublime%e5%a6%82%e4%bd%95%e8%bf%90%e8%a1%8cphp","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/20740\/","title":{"rendered":"sublime\u5982\u4f55\u8fd0\u884cphp"},"content":{"rendered":"<blockquote><p>\n  \u4f7f\u7528 sublime text \u8fd0\u884c php \u7684\u6b65\u9aa4\uff1a\u5b89\u88c5 php \u6784\u5efa\u7cfb\u7edf\uff1b\u4fdd\u5b58 php \u6587\u4ef6\u4e3a .php \u6269\u5c55\u540d\uff1b\u901a\u8fc7\u547d\u4ee4\u884c\u6216 sublime text \u4e2d\u7684\u6784\u5efa\u9009\u9879\u8fd0\u884c php \u811a\u672c\uff1b\u8bbe\u7f6e php \u8def\u5f84\uff0c\u5982\u679c sublime text \u627e\u4e0d\u5230 php \u53ef\u6267\u884c\u6587\u4ef6\uff1b\u4f7f\u7528\u5feb\u6377\u952e ctrl + b\uff08windows\/linux\uff09\u6216 cmd + b\uff08mac\uff09\u5728\u7ec8\u7aef\u4e2d\u8fd0\u884c\uff0c\u6216 ctrl + alt + b\uff08windows\/linux\uff09\u6216 cmd + option + b\uff08mac\uff09\u5728 sublime t\n<\/p><\/blockquote>\n<p><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/202404\/03\/2024040316542495109.jpg\" class=\"aligncenter\" title=\"sublime\u5982\u4f55\u8fd0\u884cphp\u63d2\u56fe\" alt=\"sublime\u5982\u4f55\u8fd0\u884cphp\u63d2\u56fe\" \/><\/p>\n<p><strong>\u5982\u4f55\u5728 Sublime Text \u4e2d\u8fd0\u884c PHP<\/strong><\/p>\n<p>\u8981\u4f7f\u7528 Sublime Text \u8fd0\u884c PHP\uff0c\u8bf7\u6267\u884c\u4ee5\u4e0b\u6b65\u9aa4\uff1a<\/p>\n<p><strong>1. \u5b89\u88c5 Sublime Text Build System<\/strong><\/p>\n<ul>\n<li>\u6253\u5f00 Sublime Text\u3002<\/li>\n<li>\u8f6c\u5230\u201c\u5de5\u5177\u201d\uff08Tools\uff09&gt;\u201c\u6784\u5efa\u7cfb\u7edf\u201d\uff08Build System\uff09\u3002<\/li>\n<li>\u4ece\u4e0b\u62c9\u83dc\u5355\u4e2d\u9009\u62e9\u201cPHP\u201d\u3002<\/li>\n<\/ul>\n<p><strong>2. \u4fdd\u5b58 PHP \u6587\u4ef6<\/strong><\/p>\n<p><span>\u7acb\u5373\u5b66\u4e60<\/span>\u201c\u201d\uff1b<\/p>\n<ul>\n<li>\u4f7f\u7528 Sublime Text \u521b\u5efa\u6216\u6253\u5f00\u4e00\u4e2a PHP \u6587\u4ef6\u3002<\/li>\n<li>\u5c06\u6587\u4ef6\u6269\u5c55\u540d\u4fdd\u5b58\u4e3a .php\u3002<\/li>\n<\/ul>\n<p><strong>3. \u8fd0\u884c PHP \u811a\u672c<\/strong><\/p>\n<ul>\n<li>\u8981\u4ece\u547d\u4ee4\u884c\u8fd0\u884c PHP \u811a\u672c\uff0c\u8bf7\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\uff1a<\/li>\n<\/ul>\n<pre>php &lt;php_file_name.php&gt;<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<ul>\n<li>\u8981\u4ece Sublime Text \u4e2d\u8fd0\u884c PHP \u811a\u672c\uff0c\u8bf7\u6267\u884c\u4ee5\u4e0b\u64cd\u4f5c\uff1a<\/li>\n<\/ul>\n<pre>* \u9009\u62e9\u201c\u5de5\u5177\u201d\uff08Tools\uff09&gt;\u201c\u6784\u5efa\u201d\uff08Build\uff09\u3002\n* \u9009\u62e9\u201c\u8fd0\u884c\u201d\uff08Run\uff09\u3002\n* PHP \u811a\u672c\u5c06\u5728\u7ec8\u7aef\u7a97\u53e3\u4e2d\u8fd0\u884c\u3002<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<p><strong>4. \u8bbe\u7f6e PHP \u8def\u5f84<\/strong><\/p>\n<p>\u5982\u679c Sublime Text \u65e0\u6cd5\u627e\u5230 PHP \u53ef\u6267\u884c\u6587\u4ef6\uff0c\u60a8\u9700\u8981\u8bbe\u7f6e PHP \u8def\u5f84\u3002<\/p>\n<ul>\n<li>\u6253\u5f00 Sublime Text\u3002<\/li>\n<li>\u8f6c\u5230\u201c\u9996\u9009\u9879\u201d\uff08Preferences\uff09&gt;\u201c\u8bbe\u7f6e\u201d\uff08Settings\uff09\u3002<\/li>\n<li>\u5728\u201c\u7528\u6237\u8bbe\u7f6e\u201d\uff08User Settings\uff09JSON \u6587\u4ef6\u4e2d\uff0c\u6dfb\u52a0\u4ee5\u4e0b\u884c\uff1a<\/li>\n<\/ul>\n<pre>\"php_path\": \"\/path\/to\/php\"<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<ul>\n<li>\u5c06 \/path\/to\/php \u66ff\u6362\u4e3a PHP \u53ef\u6267\u884c\u6587\u4ef6\u7684\u5b9e\u9645\u8def\u5f84\u3002<\/li>\n<\/ul>\n<p><strong>5. \u4f7f\u7528\u5feb\u6377\u952e<\/strong><\/p>\n<p>\u60a8\u53ef\u4ee5\u4f7f\u7528\u5feb\u6377\u952e\u66f4\u5feb\u901f\u5730\u8fd0\u884c PHP \u811a\u672c\uff1a<\/p>\n<ul>\n<li> <strong>Ctrl + B<\/strong>\uff08Windows\/Linux\uff09\u6216 <strong>Cmd + B<\/strong>\uff08Mac\uff09\uff1a<strong>\u5728\u7ec8\u7aef\u4e2d\u8fd0\u884c<\/strong> <\/li>\n<li> <strong>Ctrl + Alt + B<\/strong>\uff08Windows\/Linux\uff09\u6216 <strong>Cmd + Option + B<\/strong>\uff08Mac\uff09\uff1a<strong>\u5728 Sublime Text \u4e2d\u8fd0\u884c<\/strong> <\/li>\n<\/ul>\n<p><strong>\u6ce8\u610f\uff1a<\/strong><\/p>\n<ul>\n<li>\u786e\u4fdd\u5df2\u5728\u7cfb\u7edf\u4e2d\u6b63\u786e\u5b89\u88c5 PHP\u3002<\/li>\n<li>\u5982\u679c\u60a8\u5728\u8fd0\u884c PHP \u811a\u672c\u65f6\u9047\u5230\u95ee\u9898\uff0c\u8bf7\u68c0\u67e5\u7ec8\u7aef\u7a97\u53e3\u4e2d\u7684\u9519\u8bef\u6d88\u606f\u3002<\/li>\n<li>Sublime Text \u8fd8\u53ef\u4ee5\u4f7f\u7528\u5176\u4ed6\u6784\u5efa\u7cfb\u7edf\u6765\u8fd0\u884c PHP \u811a\u672c\u3002<\/li>\n<\/ul>\n<p>\u4ee5\u4e0a\u5c31\u662f\u5982\u4f55\u8fd0\u884cphp\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4f7f\u7528 sublime text \u8fd0\u884c php \u7684\u6b65\u9aa4\uff1a\u5b89\u88c5 php \u6784\u5efa\u7cfb\u7edf\uff1b\u4fdd\u5b58 php \u6587\u4ef6\u4e3a .php \u6269\u5c55\u540d\uff1b\u901a\u8fc7\u547d\u4ee4\u884c\u6216 sublime text \u4e2d\u7684\u6784\u5efa\u9009\u9879\u8fd0\u884c php \u811a\u672c\uff1b\u8bbe\u7f6e php \u8def\u5f84\uff0c\u5982\u679c sublime text \u627e\u4e0d\u5230 php \u53ef\u6267\u884c\u6587\u4ef6\uff1b\u4f7f\u7528\u5feb\u6377\u952e ctrl + b\uff08windows\/linux\uff09\u6216 cmd + b\uff08mac\uff09\u5728\u7ec8\u7aef\u4e2d\u8fd0\u884c\uff0c\u6216 ctrl + alt + b\uff08windows\/linux\uff09\u6216 cmd + option + b\uff08mac\uff09\u5728 sublime t \u5982\u4f55\u5728 Sublime Text \u4e2d\u8fd0\u884c PHP \u8981\u4f7f\u7528 Sublime Text \u8fd0\u884c PHP\uff0c\u8bf7\u6267\u884c\u4ee5\u4e0b\u6b65\u9aa4\uff1a 1. \u5b89\u88c5 Sublime [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16],"tags":[],"class_list":["post-20740","post","type-post","status-publish","format-standard","hentry","category-16"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/20740","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/comments?post=20740"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/20740\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=20740"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=20740"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=20740"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}