19.2.7 Popular IDEsThis is NOT the latest copy of this book; click here for the latest version.
As with other languages, PHP has a number of IDEs to make your programming life as easy as possible. There isn't space here to print a definitive list of IDEs, but there are six IDEs that I've heard good things about. Alphabetially they are:
-
DzSoft PHP Editor
-
Maguma Workbench
-
NuSphere PhpEd
-
PHP Coder
-
PHP Expert Editor
-
Zend Studio
It's not really for me to pass judgement on any of them, particularly as some (like PHP Coder) are available free. Please don't bug me if your favourite PHP editor isn't in the list. Having said that, I will tell you these two things:
-
I write most of my code using Kate, the free text editor bundled with KDE. This is not because it handles PHP well (I get syntax highlighting and nothing else!), but because it's fast, free, and does most of what I need.
-
Whenever I want to debug a script, run profiling, or am working on a project of any complexity, I use Zend Studio. It's the only product I trust 100% to do what I need. No, Zend didn't pay me to say that!
Yes, I know the Zend Studio isn't free, but here you'll find that Firth's law of tailoring applies: "no matter how many alterations, cheap trousers never fit". In the IDE world, that translates to: "it's better to pay for something that suits you first time, than have to put up with various bugs/quirks/feature holes in something cheaper." This applies doubly if you make a living out of your PHP scripting.
I don't want to dwell on this too long, but, briefly, here's what makes me want to use Zend Studio:
-
The debugging is first class. Pause your execution wherever you want, inspect and change variables, place watches and breakpoints, look into the output buffer, and step into and out of functions.
-
Profile your scripts. Select any script, run it through Zend Studio, and it will report how long each part of your script took to execute - this is invaluable for performance tuning.
-
Static code analysis. Zend Studio has a set of built-in rules that it can apply to your script to try to find possible errors. For example, if you create a variable that isn't used, Zend Studio will spot it.
-
Code completion. The code completion in Zend Studio contains the parameter list as well as the function description. If it's a user function, you can add comments to your source code that Studio will pick up and use here.
-
Browser integration. You can profile and debug your scripts entirely through your web browser - fill in a form, hit "Debug forms", then click Submit to jump straight into Zend Studio.
-
More than just an editor. You get FTP support (including SFTP, for use through SSH), CVS support, project management, and other environment tools that smooth your workflow.
Right, that's enough of that - I suggest you give all of them a try and see what fits you most. Like I said, I've heard good things about the six I listed, and everyone has their own opinion.
At the time of writing, I believe you can get a free copy of Zend Studio for educational use - ie, inside a school. You can also get a heavily cut-down version of Zend Studio (called "Personal Edition") for your personal, non-commercial use. By "heavily cut-down" I mean there's no profiler, code analyzer, CVS, FTP, remote debugging, or other helpful features, so it really is quite simplified.
That said, there's an excellent, free debugger and profiler out there, called Xdebug. Download it from http://www.xdebug.org/ and try it out.
|
Want to see this stuff in print? PHP in a Nutshell takes the core topics covered here, adds in thousands of edits from the editorial team and myself, and combines them to make an unbeatable reference for PHP programmers at all levels.
My latest book has hundreds more tips on how to use PHP, Apache, and MySQL, plus Perl, Python, shell scripts, performance tuning, and more!
|