1.添加php的环境变量
2.编辑sublime编辑器
将文件中的内容替换成:
{ "cmd": ["php", "$file"], "file_regex": "php$", "selector": "source.php"}
然后按ctrl+b即可以运行php代码了