1 Star2 Stars3 Stars4 Stars5 Stars (1 votes, average: 5.00 out of 5)
Loading ... Loading ...

Introduction

Personal productivity depends on the tools greatly, so I pay much attention to the programs I use. My previous post in this field was about MySQL workbench which I consider the best free DB design tool for MySQL.

When I started coding PHP, I used Linux so I used Kate, which only had syntax highlighting and allowed to save multiple files opened as a project :) Next was Quanta, the Linux IDE for PHP. I spent lots of time developing there until I installed trial version of Zend Development Environment (ZDE) 5.5. That was really cool. I liked it very much and used for quite long time. Around half a year ago I heard about NetBeans and decided to try it out. I was thinking quite long about it, I didn’t have enough time to install and go through all it’s functions. Finally I saw that I will never have this time, so I started using it around 1.5 months ago. While using, I was putting down some notes about the things I liked and the ones I didn’t. So now I just want to present my list :)

Advantages

What I really liked about NetBeans is that it is “the only IDE you need”. It has excellent Java support, good HTML, JS and PHP support and it even has C++ support, but I didn’t try it out, I use the old good Visual Studio 6 :)
So here are the things I liked:

  • HTML support is excellent. It founds tag mismatch, highlights start and end tags (this is extremely helpful when you deal with large portions of bad-formatted code
  • When you’re in HTML scope, and typing “<p style=”, it adds double quotes automatically! Little, but very nice feature :)
  • Code formatting is great in everywhere. When working in Zend Studio, I was using 3rd party tools to format HTML, NetBeans does it perfectly. As for other languages, the only problem I have with it is that NetBeans puts opening curly bracket on the same line as loop or function definition, I like putting it on the next line so I see opening and closing brackets one under another. However, it highlights the opposite bracket, so it’s not a big problem :)
  • Greatest thing I got there is normal debugging in PHP, not just “echo”, “print_r()” and “exit”. NetBeans integrates with XDebug and it is VERY convenient. It provides normal info as any other debugger – stack trace, local variables, superglobals, watches etc. It saves great amount of time. The only drawback is that NetBeans starts debugging session slowly, but it is definitely faster, than “echo” and “exit”
  • When switching from Zend Studio, I experienced some inconveniences because NetBeans uses other shortcuts. However, it provides more useful shortcuts than ZDE, and I got used to it quickly
  • When you code in languages like JS or PHP, where using variables without declaration is not compilation error, it is a common mistake to misspell variable and then get some interesting bugs. That’s where variable highlighting helps greatly. In NetBeans you can put cursor into any variable and in a second you’ll see all occurrences of this variable in the file. That is also very helpful when you are digging through someone’s code
  • Search is also much better, than in Zend. When you search in files, search results are grouped by file. When you search in the file, you get all occurrences highlighted. This is also very useful when you’re looking into someone’s code or performing some refactoring
  • Commenting support is also great. For example, you write some //comment. If the line is long, you want to break it into several lines and press enter when you’re inside the line. NetBeans inserts line break and next line continues as comment! This is so helpful when you’re commenting some file and your comments are quite long.
  • PHPDoc support is also great. The fact, that you get help for function, its arguments and return value if you specify function description in the PHPDoc format wasn’t new to me, but if you start writing PHPDoc comment for the ready function and put “/**“, you immediately get full PHPDoc template – all arguments list with placeholders, @return keyword, so everything remained is only put actual description, everything is automated. That’s great! The only thing I’d like to add here is that when function definition is changed, it should update PHPDoc comment – remove correspondent line or add more variables :) I guess, that’s a dream
  • Very useful feature is auto-reloading files. You don’t need to reopen log every time it is updated. However, there is a slight disadvantage – if file is deleted in the file system, it doesn’t propose to save a copy like Zend does.
  • It has built-in diff tool. It is MEGA-useful :) I have to compare files quite frequently, I was using WinMerge before that, but it was inconvenient. NetBeans integrates everything in one environment and it is very nice!
  • Auto-complete is better, than in ZDE, it takes scope into consideration. However, it is sometimes buggy.
  • In NetBeans you can view your DB in the same IDE, perform queries, view tables structure and much more. This tool is not as good as phpMyAdmin, so I am using the latter most of the time. Main reason is that NetBeans is slow when switching from code mode to the DB mode. But maybe that’s my PC :)

Disadvantages

And now some things I didn’t like:

  • Code templates are worse, than in Zend Studio. This thing is really simple there and behaved as supposed. In NetBeans I add some template, e.g. “echo ‘<pre>’.print_r($var,true).’</pre>’;” for the “pri” keyword. And sometimes it doesn’t appear, sometimes it is inserted with additional
  • There is no PHP or JS help integrated into IDE. In Zend Studio I could select php function and click “F1″ and get full help. In Aptana IDE there is the same for JS, but there is noting like this here! Why? Is it something complex?
  • No FTP support without additional plug-ins. I didn’t have time to explore this feature, but I don’t like the fact I have to install something more for such common feature :)
  • There is UML package for Java, why there is nothing like this for JS?

Conclusion

Anyway, despite of the disadvantages, I think, that NetBeans is better, because it offers even more features, than Zend, but for free! And it’s really good with Java :) I especially liked refactoring there. Just put the name of the class and everything is changed correspondently!

What are your thoughts about NetBeans? Are you using/planning to use it? What are your workarounds for the disadvantages I noted? Can you add more “pros”?

No related posts.

Related posts brought to you by Yet Another Related Posts Plugin.

Share this post with a friend Share this post with a friend

14 Comments

  1. Sergei says:

    Hi!

    And how about Aptana IDE? I’m using it for about 9 month and very very like it.

  2. Konstantin Mirin says:

    I’ve used it for JS projects. It’s a good thing, but it seems NetBeans is better, just because it’s “the only IDE you need”. Aptana’s speed is just the same as NetBeans’s, code highlighting is the same, but it doesn’t offer diff tool, excellent PHP support and many other good things. However, I was using quite old one, not the newest. Does the newest version support PHP debugging?
    I’m not going to dispute about the best IDE, I just share my experience about NetBeans – the things I liked and the ones I didn’t

  3. Sam says:

    Yes, there is PHP debugging support in the latest Aptana version.

    NetBeans >6.5 supports FTP natively (6.7m1, nightly).

  4. Konstantin Mirin says:

    I’m using 6.7m2 (2009-02-23), I didn’t tell this cause 6.5 is a stable branch, so I wrote about it. Things I noted are the same in both versions. (well, seems except ftp)

    And how do you use FTP there? I didn’t find it :)

  5. jz says:

    I use Eclipse with Aptana+Spket+PDT+(couple other plugins) for web development. It’s very well configurable and plugable.

  6. Konstantin Mirin says:

    I heard PDT is slower, than NetBeans. I wanted to try it, even before installing NB, but I had problems with installing it from eclipse environment and didn’t have lots of time to look into this. So I gave up. Maybe I’ll try your variant when I have time. If so – I’ll definitely write my feedback on this.

  7. Daniel says:

    PDT or ZDE for eclipse is very good.
    actually ,ZDE for eclipse is best. the problem is it is not free.
    if you wish,you also can try php for visual studio on windows platform.
    for now ,Zend was released Zend Debugger ,it’s better than Xdebug.
    but i am against to use debug in PHP. in my mind ,it’s needn’t.

  8. Konstantin Mirin says:

    Zend products are better, but they are not free, that is the problem.

    Re: debugger. Have you tried searching a bug in a complex framework? I do this regularly and I asure you – debugger makes my life easier :)

  9. Thành Đạt says:

    I am using Netbeans in my daily PHP works, everything is cool.
    But one thing I don’t like in Netbeans, when I add a large project, it scanning prj is very slow, and daily I open Netbeans, it scan again.

  10. Konstantin Mirin says:

    Yes, it should cache the large project tree. On the other hand, when you add something from outside (e.g. using explorer instead of NB), this file is shown immediately.
    But I agree there is possible to find some good solution for effective caching. Hope there will be one in NetBeans 7 :)

  11. Kevin Kaland says:

    I’ve been on an IDE hunt lately because for various reasons I started using Linux for my testing environment (PHP just executes a lot faster than WAMP on a Windows XP VM…)

    Anyway, on Windows, my definitive PHP IDE of choice is phpDesigner. It just keeps getting better. If you don’t mind paying a bit, it’s a GOOD BUY. I would upgrade mine if I wasn’t currently using Linux. The developer is a nice guy too.

    On Linux, I started with Eclipse, but PDT was slow on my 1GB-RAM Ubuntu VM. It’s unfortunate, because it had all the features I wanted. I can’t get by with characters taking a second each to appear though.

    So I went to the latest Netbeans 6.7. Better, overall, some really nice features, but the debugging wasn’t the way I liked (I don’t want it to open a browser for me – I want to connect my own browser from another computer). The code completion also lacked intelligence in some areas. For better or worse, code completion and syntax highlighting are probably THE biggest features I want in an IDE.

    So I tried Aptana. A bit better, but still weak on the code completion when I needed it. I might go back to it if they improve this part…it was pretty sweet, a lot nicer at the moment than PDT except for the dodgy code completion. I heard they’re contributing some of their PHP plugin code to PDT. I can’t wait; Aptana actually has decent word wrap. So I may need to check this out again.

    But anyway, I was at my wit’s end. I supposed it was time to go back to Windows. I had to pull a couple Bazaar branches (my VCS) from my Linux image before I could do that, though, so I figured hey, I keep reading about Vim as a PHP IDE – sounds crazy, but why not give it a shot? So I got down to it…and lo and behold, it actually does the job alright. Takes a little bit to set up, but there’s good documentation, and it’s customizable in all the right ways. A breath of fresh air for a programmer, and my customizations should be usable cross-platform with minimal effort – a nice thought.

    I’m still deciding if I’m going to stay with Vim or not – maybe I’ll try one of those IDEs that integrate it as the editor – but it’s actually pretty cool and works for me for the moment.

    Hope to read more about your IDE search…

    Kevin

  12. James from FaceySpacey.com says:

    Aptana Cloud’s automated/simplified deployment solutions that work in concert with Aptana Studio really are powerful. It’s too bad that Aptana Studio (the IDE) isn’t as good as Netbeans and Zend Studio. I wonder what the best solution is to get functionality like Netbean’s Diff tool in Aptana (just switch back and forth between programs)??? What’s the best way to stay in Aptana, but get some of the goodies of the other tools?

  13. SowingSadness says:

    NetBeans dosen’t support:
    – Mylyn analog.
    – Git.
    – and more…more…more

  14. Konstantin Mirin says:

    It supports Git :) I think functionality of Netbeans is OK for every day PHP development. But sure, there are things that are not in there :)

Leave a Reply