Why PHP is so special

Well, I thought I’d take ten minutes and reply to this article post on TSS asking what was so special about PHP. I’ve been using PHP since well before 4.x came out, and I consider myself very experienced.

  • It’s easy to install: runs as a CGI script or an Apache module.
  • It doesn’t “hog resources” — WAY less resource intensive compared to Tomcat + $whatever
  • Most web hosts have it installed already
  • It’s easy to learn (Easier than Perl, IMO)
  • Great for rapid development
  • No futzing with CLASSPATH, JARs/Servlets/Servlet Containers/Beans/Deployment Descriptors/etc
  • MySQL connectivity “out of the box” (relates to no JAR files, etc)
  • Huge function library (http://www.php.net/manual/en/funcref.php) - Much of it is already enabled by default.
  • GREAT documentation. (http://www.php.net/docs.php) You can type www.php.net/functionName and get teleported to the docs for functionName

Most of the reasons I can come up with for using PHP focus around pure speed of development, as well as having a fairly low barrier to entry for learning. The syntax is simple, and all you need to learn is a language, as opposed to learning about Java, JSP, Servlets, containers, etc (see above).

However there are many cases where I *wouldn’t* use PHP, which perhaps I’ll write about later. Here’s a hint: I like Cocoon a lot :)

Comments are closed.