On 16 Aug 18:18, Peter Alcibiades wrote:
A friend asked me what he should use to write PHP in. Never having done any of this stuff, I had no idea, except that maybe Geany or Kate would work.
What do you guys use?
Also, he is setting up Linux for the first time. I recommended Mandriva to him, as being more familiar than some of the alternatives. But if he wants to run his PHP, once he has written it, what does he need to install? I am guessing that Apache would work, but is there something simpler and lighter for him to get started on?
Depends on if it's for a quick and dirty setup or for production deployment. If it's for quick and dirty and is a locked down to own machine style setup, with no other users etc, then using apache2 and mod_php is probably the quickest and easiest method - however, this locks you in to using the prefork mpm which is (frankly) pants.
For production deployments, you'd be looking more at apache2 + mod_fcgid + php5-cgi, and setting the user for the fastcgi daemon as something that *isn't* the main web server user.
For very small local development it might be worth looking at using lighttpd with the fastcgi module, and using php in fastcgi mode.
As for which editor/IDE to use, that really is a matter of user preference, personally I use vim for everything, but apparently several people can't get thier head around a mode-based editor...
I'm not sure what kate's PHP syntax support is like these days, but it used to be flaky at best, so, with that in mind, I'd be thinking {x,}emacs, jedit or (as has been suggested) eclipse.
Cheers,