PHP开发的IDE 有很多,但是用得比较习惯的还是EditPlus,方便易用,虽然没有Eclipse 那样的代码提示自动完成这么只能,但是做一般的开发已经足够了。
EditPlus (官方网站:http://www.editplus.com/),里面可以找到下载地址;
一、PHP代码美化
好吧,我有强迫症,看到不对齐的代码就要一个个空格敲到整齐为止,下面就介绍一个EditPlus的插件。
用到以下工具:
PHP Code Beautifie (官方网站:http://www.waterproof.fr/,里面还有其他的美化工具)
插件下载地址 http://www.waterproof.fr/products/phpCodeBeautifier/download.php
(1)安装
先 把PHP Code Beautifie 下载下来,解压放到editplus 安装目录下.
(2)配置工具
在editplus 下点 工具>参数>用户工具>增加工具>程序(英文版的是 Tools>Prefrences>UserTools>AddTool>Program)
菜单名字:自己随便写一个名字,比如我这里叫【PHP代码美化】
命令:浏览到我们刚才下载的phpcb.exe
参数:(具体什么意思,看下载时附的文档)
–space-after-if –glue-arrow –optimize-eol –space-after-switch –space-after-while –space-before-start-angle-bracket –one-true-brace-function-declaration –one-true-brace –extra-padding-for-case-statement –glue-amperscore –change-shell-comment-to-double-slashes-comment
–indent-with-tab –force-large-php-code-tag –force-true-false-null-contant-lowercase –comment-rendering-style PEAR –equal-align-position 50 –padding-char-count 1 “$(FilePath)”
起始目录:$(FileDir)
注意:下面一定要选上 文本过滤器模式运行 替换
(3)设置如下图:
使用的时候,按Ctrl+1就可以用了。
本文链接:http://www.leake86.net/blog/?p=58,转载请保留;