php格式化工具Beautify PHP小小BUG

作者:袖梨 2026-09-21
Beautify PHP is written entirely in PHP.The program was tested with Linux and Windows, PHP 4.1.0 and PHP 4.3.1, but it should work on most systems running PHP.

BeautifyPHP,很好用的php格式化工具 http://www.b*ie*rka*ndt.org/beautify/ http://pear.p***hp.net/package/PHP_Beautifier/download最近组内来新人,他们代码不太规范的时候看得实在不舒服 这个工具实在很好用,再乱的代码瞬间就格式化好了 丢到linux下还可以快速批量处理@.@ 好了,以下是本帖主题: BeautifyPHP格式化符号时,遗漏了^=和&=判断, 在beautify_php.class.inc第426行,增加这两个符号 //addspacebeforechars=<> if($i>0AND!$this->_comment){ if(($a[$i]=="="OR$a[$i]=="<"OR$a[$i]==">"OR$a[$i]=="*") ANDpreg_match("/([|!|=|.|<|>|-|+|*|/|^|&]+)/",$a[$i-1])==0){ $this->_outstr=rtrim($this->_outstr).""; } }

相关文章

精彩推荐