Comments on: Andreessen: PHP succeeding where Java isn't
Netscape pioneer Marc Andreessen says the scripting language is better, simpler, and has a brighter future than Java.
Netscape pioneer Marc Andreessen says the scripting language is better, simpler, and has a brighter future than Java.
December 5, 2009 11:20 AM PST
December 5, 2009 10:58 AM PST
December 5, 2009 10:03 AM PST
Add headlines from CNET News to your homepage or feedreader.
More feeds available in our RSS feed index.
Related quotes
I go to work and develop J2EE application for 8 hours and then come back home and freelance for another 3 hours where I am building a OO PHP application.
So from a perspective of a developer who programs both PHP and Java, I get more satisfaction working on PHP than Java. I feel more creative without worrying about application server's J2EE implementation, hibernate's caching issues etc etc.
I don't know about the future, but as a developer I would always prefer PHP over Java.
Google uses it and so does Industrial light and magic of star wars fame !
Not to say that PHP is a bad language/platform. It is well suited for very simple things and very small teams. PHP has a very low entry-barrier, so, I can see the average competence of a PHP person is lower than a Java person (and both are lower than a Python or Ruby guy). PHP just appeals to the wrong audience.
I wouldn't risk a big and complex application to be written in PHP by average PHP programmers.
And, since all Netscape code had to be thrown out before Mozilla could walk (it was considered "garbage" if I remember correctly) Andreesen is not the person I would ask about quality.
The whole notion that you need .net or Java for enterprise apps is bunk. LAMP works fine.
The problem with PHP is the usual one of a site starting out small, getting some usage, being added to, growing and ending up a mess of spagetti code.
This problem occours with JSP as well, but GOOD refactoring IDEs (IntelliJ's IDEA for example) make it a simpler task to bring the beast under control.
I haven't seen any IDEs for PHP that have the range of features and stability that say IDEA has.
Your LAMP (Linux Apache MySQL PHP) simply becomes Linux Apache/Tomcat MySQL Java/JSP.
No part of that costs any money except for the MySQL licence. MySQL has very robust JDBC drivers and Apache integrates just as well with Tomcat as it does with PHP.
from its millions of users. eBay is built on Java. BTW, I myself get
tired of SourceForge's hiccups (PHP), and the many PHP sites that
give me the 'can't connect to database' error.
I'm not even a Java fan (I develop 'LAPP' - Linux, Apache,
PostgreSQL, Python), but I'm amazed at the ignorance displayed by
the fan boys on this board. Hope you PHP guys monitor BugTraq!
watch this: http://public.yahoo.com/~radwin/talks/php-at-yahoo-zend2005.pdf
2. php can scale but requires more discipline then the more rigid java
3. who cares?
Java is faster then most people give it credit for.
Java is an easy langauge to learn
Java can be used for any programming project you can think of. It is not the best choice for everything of course, but it is not limited.
Personally I like c and C++ a bit better, but always enjoy using java also. php doesn't feel like a professional language. Sure it is quite nice and can do powerful stuff with it, but I put it in the same category as VB, a fun toy.
What I would like to see is a langauge with the clean syntax and garbage collection of java with the what makes C++ so good. Basically a cleaned up C++, and it is a mess, with garbage collection and a logical, orderly library. Funny thing about C++ is that it is such a huge, sprawling language, but lacks basic features that java has, like a networking and GUI library. I always thought it odd that there are a million functions to take in input in C++, but sockets are not part of the standard language.
I'm a real believer in right tool for the job, all programming languages suck, they each suck in their own way, and in any given situation you want to use the one that sucks the least for the task at hand.
PHP is great for relatively simple templating tasks, but sucks hard if you need to do something that maintains even small in-memory data structures across multiple requests. If you want to experience true pain try doing something that requires an event queue or an in memory search index in PHP, it's possible but not exactly fun.
Java is better at supporting large teams, all the bureaucratic boilerplate starts to make sense when you need to keep twenty people from stepping on each others toes. Generally speaking, for a smaller team that doesn't need the overhead of java, you're better off using Python or Ruby to do those things that need to be run as smaller daemons.
PHP5 is a new language that has some resemblance to classic PHP, but the sad truth is that most of the PHP currently in production use is PHP4 with all the security headaches that go with things like register_globals etc.
There are no silver bullets when it comes to web programming. Don't get stuck in the trap of thinking that the programming language you know is the right tool for every job; it isn't. You will need to learn a variety of tools before you can consider yourself to be even a journeyman programmer.
Java is slow for development not because of its complexity but because of its verbosity and the fact that it has to be recompiled constantly. Throw in several layers of J2EE stack and you can end up with enough bloat to make you want to lose your lunch.
I can think of several options superior in most ways to either Java/Struts/J2EE or PHP:
- ColdFusion (Java internally but with more out-of-the-box functionality than anything)
- ASP or ASP.NET with Perl (i.e. Apache::ASP or ActiveState's PerlASPX) Perl is better for web programming than any of the standard ASP / .NET languages.
- Ruby on Rails (Ruby is probably the most beautiful language in existence, although Rails is still beta and has performance issues)
- Catalyst (Perl MVC framework similar to Ruby on Rails but with pluggable MVC components and much better performance)
another example for a serious and sensemaking php-app? - e.g. siemens doing powerplant-steering, lufthansa (german airline) ticketing system ....... but seriously ... there IS a market for J2EE, but about 80% of complexity in webapp-devpmt. can be done faster by php. prerequisite: real good developers. sw-quality, scalability, robustness is a question of people- not of technology-quality. just my 2 cents ...
that without WebObjects I would prefer PHP. However, WebObjects
tips the scales way in favor of Java. Yes it has a bit of a learning
curve but now I can develop, test and deploy much faster than the
competition and that is leading to success for our subscription
based application.
WebObjects Rocks!
- by LBL_Lowkee October 19, 2009 12:43 AM PDT
- I happened across this page while trying to find some tutorials for learning JAVA as a PHP developer and I have to say.. seeing as, 4 years after this article hit, PHP is the language behind most of the top 10 web sites on the net today.. it seems the JAVA fanboys (amazing how many veteran programmers still act like fanboys) need to face reality.. PHP owns the web and is only getting stronger. Heck, back when this article was written, I ran a #1 site with 30K concurrent users in PHP during my 1st year of programming. Since then, many times over, I have looked back at old code wondering what I was thinking when I wrote it. I was new to PHP and still managed to single-handedly write a web app which a team of coders today still has difficulty with. It seems the JAVA purists need to lift their heads and look around in between late night coding sessions, trying to make up for the thousands of extra lines of code JAVA requires over PHP. What requires 15 lines of code in JAVA, I can do in 1 line of PHP. That is the power of PHP.. oh yeah, and PHP powers 70% of the net. Seems I'm not the only one who agrees.
- Like this Reply to this comment
-
Showing 2 of 2 pages (106 Comments)Frankly, this most recent comment sums up the JAVA purist mindset:
1. Yahoo is hardly a model of a good site
Yeah, the #1 site ever runs on PHP.. it must prove how poorly PHP scales.. Add Facebook to that list, too.
2. php can scale but requires more discipline then the more rigid java
Okay, so the argument is.. "Us JAVA programmers must be locked into good coding because we're too lazy to make the correct choice ourselves". If you plan for scale, you can scale. The 'rigid' argument works as well as passing a law to require people to eat healthy. Long term planning is a part of life.
- Java is faster then most people give it credit for.
So was DOS 2.1
- Java is an easy language to learn
Easy to learn and easy to use are vastly different things. I challenge you to write a "Hello world" web app in less than 5 lines of JAVA code, because I can do it in one line of PHP. That makes me 5 times more effecient then a JAVA coder, meaning my web apps will have 5 times the features in the same timeframe.
- Java can be used for any programming project you can think of. It is not the best choice for everything of course, but it is not limited.
I only code in PHP and I have never uttered the words "I can't do that".. ever.
- PHP doesn't feel like a professional language. Sure it is quite nice and can do powerful stuff with it, but I put it in the same category as VB, a fun toy.
My favorite argument. This is what nearly every monumental invention was called upon creation.. remember Microsoft? Apple? You are browsing on the very creation of a garage hacker. You are moving a cursor with the very invention the execs at IBM scoffed at. Face it, you need to get your heads out of your suits and realize guys in t-shirts can be, and are, smarter and more forward thinking than you are.
PHP = Simple, Powerful, Efficient, Focused, A true creation
JAVA = Complex, Powerful, Inefficient, Bloated, A wannabe