PHP CodeSniffer is a very good tool to help us check our PHP source code. But the report from CodeSniffer is not easy to read.
I found that CodeSniffer can output 'Checkstyle' xml report. Is that any way to Visualize PHP code with Checkstyle xml report, so that every developer can read code and report in one page?
In fact, I found a tool named phpUnderControl, which looks like a very good Continuous Integration tool and something inside it could cover my requirement. But I have no plan to change my Continuous Integration tool (I'm using Apache Continuum).
So if anyone can tell me a simple tool or plug-in, that would be the best.
Thanks.
This is really more of a comment/question, but SO thinks it is too long so I'll phrase it as an answer:
Assuming you want to take output like this:
and render a version of the original source code with the indicated sections highlighted somehow, then I think you're going to have "to roll your own".
You'd have to write a script which takes the path to a source file in your code repository as an input parameter (e.g. path/to/code) and a chunk of "checkstyle" XML as input (via STDIN), and renders the contents of the file (to STDOUT) as HTML markup.
The body of the file inside should be in a PRE element (to preserve formatting) and each specified line + column with an HREF link to an error/warning "list element" would be at the bottom of the HTML page (I'm not sure what kind of addition color/highlighting can work inside a PRE element).
This is a good idea - I would like to have such a script/tool/utility myself! If I ever get around to writing one I promise to publish it on Github and add a link to it here.
And if you ever find/write one, PLEASE answer your own question, OK?