- Related Stories
-
Andreessen adds some Ning to the Web
October 6, 2005 -
FAQ: The Sun-Google partnership
October 4, 2005 -
Sun and Google shake hands
October 4, 2005 -
Ajax gives software a fresh look
October 4, 2005
Java enjoyed great success when its inventor, Sun Microsystems, released it in 1995, largely because it was optimized better for programmers than for machines, making software development significantly easier, Andreessen said. Unfortunately, Java has acquired many of the unfavorable characteristics of its predecessors, he added.
"Java is much more programmer-friendly than C or C++, or was for a few years there until they made just as complicated. It's become arguably even harder to learn than C++," Andreessen said. And the mantle of simplicity is being passed on: "PHP is such is an easier environment to develop in than Java."
That opinion might not sit well with Java loyalists--and there are plenty of them among the millions of Java programmers and hundreds of companies involved in the Java Community Process that controls the software's destiny.
But even some influential executives at IBM, which was instrumental in bringing Java to the server and whose WebSphere server software has Java at its core, see the benefits of PHP over Java.
"Simplicity is a huge part of it," said Rod Smith, vice president of IBM's Emerging Internet Technologies Group, describing PHP's appeal to IBM in a meeting with reporters at the conference. "They weren't interested in adding language features to compete with other languages," choosing instead "the simple way, and not the way we've done it in Java, unfortunately."
PHP is an open-source project including an engine to simple programs called PHP scripts and a large library of pre-built scripts. Much of its development is in the hands of a company called Zend, which sells packaged PHP products, programming tools and support.
Wooing programmers is nothing new in the computing industry, where players constantly jockey to establish their products as an essential foundation. Indeed, many credit Microsoft's success to its highly regarded programming tools, which make it easier for developers to write software that run on Windows.
executive director,
Eclipse
PHP has caught on widely. About 22 million Web sites employ it, and usage is steadily increasing. About 450 programmers have privileges to approve changes to the software. Major companies that employ PHP include Yahoo, Lufthansa and Deutsche Telekom's T-Online.
PHP is more limited in scope than Java, which runs not just on Web servers but also on PCs, mobile phones, chip-enabled debit cards and many other devices. Some parts of the Java technology, though, such as Java Server Pages, handle much the same function.
"Java and PHP compete at some level. Get over it," Mike Milinkovich, executive director of Eclipse, said in a meeting with reporters. Eclipse is an open-source programming-tool project that long supported Java and now also supports PHP. "I'm looking forward to PHP kicking butt in the marketplace," Milinkovich said.
Java and PHP are drawing nearer to one another, though. Oracle, which also sells Java server software and whose database software can be used as a foundation for either Java or PHP, is among those working on an addition to Java to help the two software projects work together. Specifically, Java Specification Request 223 will "help build that bridge between the Java community and the PHP community," said Ken Jacobs, vice president of product strategy at Oracle, in a speech at the conference.
And even Andreessen, who just helped launch a start-up called Ning for sharing photos, reviews or other content online, acknowledges that Java has its place.
"My new company is running a combination of Java and PHP. This is
See more CNET content tagged:
PHP, Marc Andreessen, Java, Java server, programming tool




http://wasp.sourceforge.net
It was designed to help smooth the transition from Java to PHP for
people who are used to heavy Java-centric web programming.
like Java. Actually, it doesn't at all.
modular web apps, you could say the same about a number of
competing scripting technologies. But this line is pure B.S.:
"It's (Java) become arguably even harder to learn than C++"
Ever heard of garbage collection? How about open-source APIs?
Mark should be ashamed of himself for making such
irresponsible statements.
There is a real simplicity to PHP. Through a single book, and the online php.net reference, I was able to write my first PHP app in hours. The progam I made crawled a directory of a server for certain files, parsed information out, and presented it in a report made with HTML 1.0 standard output. Yep! Just a couple of hours of work and it worked great.
On the otherhand, after weeks of reading and researching, I can do a "Hello World!" console app in Java, but that's really about it. It is, indeed, a challenge. There is a lot to the language, after all there are thousands of libraries that come with Java 5, not to mention all the libraries you can install on your own. Having so much builtin leads to bloated apps, nevermind it's still and interpreted language, just like PHP.
Internet), wrote the NCSA Mosaic web browser (the very first web
browser, without which you likely wouldn't be here), and then
founded Netscape Communications. Why don't you give us all a
ring when your "failed start-up" has done as much for the web as
he has.
Most java servlets begin like this (or something like this):
import javax.servlet.HTTPServlet;
And a few other lines like that. What's up with that? The second time I tried to learn JSP, I spent hours setting up a "reccomended" development environment using Apache, an environment which was not reccomended for "deployment".
So, trying to give Java another chance, I tried to make stand-alone applications. After all, Java is the only "interpreted" language that includes built-in support for GUI design. So I started to design an interface using a GUI program (netbeans) (I don't think many people actually CODE their interface design in Java). I spent about an hour setting up two buttons, two labels and one button just the way I wanted. It's because of the layout I was using. These "layouts" are the most ridiculious idea I've ever heard. But never fear, the Absolute Layout lets me put my controls where I want. Only problem is, it's part of the netbeans IDE, and without netbeans installed, it doesn't work.
All in all, the difficulty of setting up a Java environment, the clutter of the language (look up how to read data from the console for an example) and all the object-oriented mumbo jumbo will eventually lead Java to its downfall.
JSP is an APPILCATION of java. How can you apply java if you do not know it?
Import statements are simple.
import javax.servlet.HTTPServlet
That imports the class file named HTTPServlet in the existing class so it can use it. It tell the compiler it is found in the package(basically a folder) named javax, and servlet is a package inside javax.
What is complex about that?
I agree the layouts could be handled better, but are similar to GUI libraries for many languages. Your main problem is you do not know the langauge. Learn the language(very, very easy) and swing and servlets will be a cakewalk too.
Try learning the C++ standard template library without knowing C++. Doesn't work. You need to learn php before you can use that too.
Java is not for the consummer application, it's for dummy geeks. Marc is right.
It's just as easy to screw up a PHP application as it is to screw up a Java application.
As noted in the article, here's hoping PHP doesn't fall into this trap like Java and just about everything else.
And look at the way most PHP code is being written - plain crap. If you say that PHP is easy language - I can say that it is easy for creating crap code. If you want to make something usefull and reusable then Java or .Net is much better choice.
And I can not believe my ears when I hear people complaining about object oriented programming.
I think it's time to realize that programming is one of the hardest tasks for human brain - so not everyone can be a programmer even if they try hard. So I am not blaming those people who choose PHP - they are just the ones that can not/do not understand how real programming works.
displacing the other, but I disagree with the
denigration of PHP. Caching -- it's supported
in PHP more or less as it is in .Net and Java,
you might not be aware of it, but it doesn't
mean it isn't there for those who are.
Further, like anything else in programming, the
language is simply a tool. Different languages
are inherently better at approaching different
problems and performing certain function based
on their design. Anyone that has spent much time
programming a variety of languages is keenly
aware of this. Sometimes there are external
factors that influence language choice for
development too, but as a programmer you
generally want to select the right tool for the
job.
What's the right tool for the job? It depends.
PHP is great for simple logic, interfacing with
the OS, and manipulating XML or dealing with
SOAP. Java has great OOP, introspection, rich
support libraries, etc. It should be plainly
obvious to anyone familiar with both languages
as to when is a superior solution to a specific
task. I find that I write in both languages
quite a bit (and, in my field, most everything I
write is new and there are no overriding
constraints on what I choose).
Andreessen is using Java on his own site...why is that? Excuses, excuses... PHP is fine (IMO of course) if you want to do simple things and aren't terribly concerned about throughput. In terms of processing business logic, I'd guess Java is around 10x faster on the same hardware. The impressive thing with Java is the performance achieved with a bytcode interpreted language.
Try Java with a good framework like Wicket, and I'm pretty sure PHP will start to look a lot less appealing.
By the way, one thing to watch out for with PHP is getting locked into MYSQL, since the default database stuff is MYSQL specific. At least Java is nicely database agnostic.
HIH.
.. one thing to watch out for with PHP is getting locked into MYSQL, since the default database stuff is MYSQL specific ..
Unquote
Real-life applications are about data. Database work is one of those areas I think PHP excels. It has built-in functions to access MySQL, InterBase, MS SQL,Informix,mSQL, Oracle, PostgreSQL, Sybase etc. PHP does not make any database the default - you must consciously select your database through the relevant function. The reason PHP seems to be nearly always linked to MySQL is that MySQL is the most widely-used open-source database on earth, and just about every web host supports it. But within the same PHP application you can effortlessly access several databases.
I gave up on Java because of the difficulty accessing databases of my choice. Also, I love to be able to write my application and be sure it will run without worrying if the user has the right run-time engine installed on his/her machine.
http://www.100days.de/download.php?id=i/677.pdf
On the above-mentioned ?Zend PHP Conference & Expo? in San Francisco Gaylord Aulke, CEO and founder of 100 DAYS, gave a substantial tutorial on ?Comparing PHP, Java/J2EE and ASP for web application management?. Aulke is also deeply involved in the PHP-framework-development-initiative. 100 DAYS develops in Java/J2EE as well as in PHP. Another Track given by Gaylord Aulke on the PHP Conf & Expo is a Case together with Boehringer Ingelheim, Top20 Pharma-Producer worldwide and Customer of 100 DAYS concerning PHP2SAP-Integration ( more info: http://zend.kbconferences.com/speakerbios.php#session203 )
Might be helpful for getting some more detailed and objective insight in the topic.
regards from germany,
hb
Java is a liberal arts professor stuck in an ivory tower, crippled into inaction by his own perfection. He is oh-so-much more enlightened about the theory of programming than the 'little people', but he'll never really be anything other than what he is now.
PHP is an aggresive problem solver who drops out of college to start his own company and ends up one of the richest and most influencial men in the world.
obvious.
I guess some 3-4 million programmers building the majority of
enterprise applications in the largest companies on the planet
are also oh-so-much more enlightened about the theory of
programming than the 'little people'.
PHP is a good scripting language well-suited for small web apps.
Java it is not, and won't be for at least 5-7 years, if ever.
Take your ideology elsewhere buddy, there is no place for it in a
programmer's world. We use the best tools for the job at hand.
For large scale server-side apps that means Java.
A very smart man once said to me "I don't love software, I love
women". Think about that before you start calling others
ideologues.
mark d.
1. Since PHP is a simpler language, one must assume the barriers that prevent less experienced developers to write software will be lowered. PHP must be able to safely execute within a sandbox.
2. Provide default automatic filtering of dangerous arguments in the REQUEST variables, such as those that typify SQL injection attacks, and cross-site scripting attacks.
3. Provide unified access to enterprise identity management. No, we don't want developers to roll their own, and neither do we want third party COTS developers to have to develop to a gaggle of APIs.
I've detailed more over my blog "PHP and the Enterprise": http://www.redmountainsw.com/wordpress/archives/php-and-the-enterprise
straightened out... what makes you think PHP will have these
features anytime soon? And to be enterprise-ready it will require
more than what you mention here... It's got a long way to go to be
a suitable environment for large-scale apps.
Giant steps, more like. A good security model is only one of many
significant hurdles that need to be cleared.
I work fro a Fortune 100 and we've decided to abandon JSP and migrate our applications to PHP.
Why? Because PHP is cheaper, and easier to use, while being just as powerful as JSP.
All you Java geeks out there who take pride in the fact that your language is hard to use, take pride in the fact that soon you'll be the only ones using it!
Java is an overcomplicate, bloated and uncessarily complex language that fails to deliver on its promises.
PHP on the other hand is easy to use, very very powerful and with Oracle now supporting it, the way ahead.
- PHP costs less
- by October 21, 2005 7:53 AM PDT
- I'm surprised nobody has brought up the cost aspect when comparing PHP and Java. I have worked for several small companies deliveriving Web application services type applications and PHP has been the clear winner for these companies in keeping their costs low. Sure, you can start with Java for very little cost but when you start to grow the service and end up getting into databases, applications servers, and the like some pretty hefty licensing fees come into play. Setting up a LAMP (Linux, Apache, MySQL, PHP) server on the other hand is wonderfully free! All you need is the hardware and even there there are tons of hosting and dedicated server companies that can provide you the platform for small change compared to the cost of an Oracle license! As for .NET, with Microsoft nickle and diming you at every turn, I don't even want to go there!
- Reply to this comment
-
-
- re
- by Bill Dautrive October 22, 2005 1:23 AM PDT
- Ever heard of Linux/Apache Tomcat/MySQL/Java
-
-
Showing 1 of 2 pages (106 Comments)As a programmer, I love programming in Java. But PHP fits the budget of the companies I work for far better. My only real problem with PHP is that I do find, as mentioned before, with PHP so easy to learn there is a lot of crap code. However, a disciplined programmer can make beautiful code in PHP too, if you know what you're doing, especially using OO in PHP5. It makes for a real headache when I hire subcontractors, weeding out the qualified programmers from the taught-my-self PHP web hacker.
The only time I yearn for Java these days is when I am forced to write explicit unit tests (PHP has PHPUnit, just like JUnit!) to test error conditions because there is no compiler to pick-up on my typo errors! Argh. Other than that, I love the way PHP can be used to implement application services over the web for so darn cheap! Practically solutions after all win out over design elegance in my world.
Charlotte
Guess what?
It is free and JSP beats the pants out of plain old CGI for basic web server programs.