安装SublimeLinter在Sublime Text3下同时按住`ctrl`+`shift`+`p`,然后输入`install`,选择`Install Package`。
![Install Package](http://ww2.sinaimg.cn/large/63c9befagw1f59rzbqew9j20ch03it91.jpg)
然后输入`sublimelinter`,选择`SublimeLinter`进行安装。
![SublimeLinter](http://ww1.sinaimg.cn/large/63c9befagw1f59rze8e55j20c60b9413.jpg)
安装完成后,会看到如下的说明。
![SublimeLinter安装](http://ww1.sinaimg.cn/large/63c9befagw1f59s24y47mj20up0if437.jpg)
安装SublimeLinter-php> SublimeLinter-php使用的是php -l 进行的检查。
> This linter plugin for SublimeLinter provides an interface to php -l. It will be used with files that have the “PHP”, “HTML”, or “HTML 5” syntax.
在Sublime Text3下同时按住`ctrl`+`shift`+`p`,然后输入`install`,选择`Install Package`。
![Install Package](http://ww2.sinaimg.cn/large/63c9befagw1f59rzbqew9j20ch03it91.jpg)
然后输入`sublimelinter-php`,选择`SublimeLinter-php`进行安装。
![SublimeLinter-php](http://ww3.sinaimg.cn/large/63c9befagw1f59s3slow5j20c90bg0vc.jpg)
配置SublimeLinter打开`SublimeLinter`的配置文件,依次点击Preferences->Package Settings->SublimeLinter->Settings - User。
在打开的配置文件里,搜索`paths`,找到下面的`windows`,配置php的绝对路径。
![配置SublimeLinter](http://ww3.sinaimg.cn/large/63c9befagw1f59s8l1u1kj20y80ljaf0.jpg)
其中的`lint_mode`,表示运行模式,可选的值有`background`, `load/save`, `save only`, 和 `manual`,这里我设置为了`save only`,只有才保存时才进行检查。
其中的`mark_style`,表示出错的显示样式,可选的值有`"fill"`, `"outline"`, `"solid underline"`, `"squiggly underline"`, `"stippled underline"`, 和 `"none"`,默认值为`outline`,出错的情况显示如下。
![出错显示](http://ww3.sinaimg.cn/large/63c9befagw1f59sgj1hywj207m043q2v.jpg)