Introduction
In our modern and technical world, the World Wide Web is a really important aspect for our economy and social life. There are several web applications on the internet to interact with friends or kindred spirits. Almost every economic tree has several reasons to present their offers in the internet. In our fast moving society it’s really important to create web applications which can be developed really fast and we should never forget the aspect of security.
I have already used three of the mainly used techniques to create web applications, ASP, JSP and PHP.
Syntax of the language
If you like the syntax of a language is more or less up to the user. In this section I just want to show a basic example of each language, before I start to compare these languages. These test scripts all show the current date in a format like “Mon, 19 Mai 2008 09:12:41 UTC”.
ASP
<html>
<head>
<title>ASP-TestPage</title>
</head>
<body>
Hi there, today is the
<%response.write(now())%>
</body>
</html>
JSP
<html>
<head>
<title>JSP-TestPage</title>
</head>
<body>
Hi there, today is the
<%= new java.util.Date() %>
</body>
</html>
PHP
<html>
<head>
<title>PHP-TestPage</title>
</head>
<body>
Hi there, today is the
<?php echo date(DATE_RFC822); ?>
</body>
</html>
Which one is the best?
First of all, it’s not possible to answer this question, because there is no best or worst language. It always depends on what the user needs, and what the developer likes to work with.
I used all of the three languages and I still don’t have a favorite language, because all of them have some good parts, and all of them have some parts which are really annoying. I created several casual websites with PHP. I used it because it’s extremely easy to use and it does the job. The problem of PHP is that you really need to create everything on your own. You don’t have predefined stuff like in JSP or ASP where you can just drag & drop to create your interface. I used JSP more or less only in school where we had to learn it (as I have never been a big fan of Java). I never really created a big project with it, but I used it for small websites there. It has actually some cool features like beans or stuff like that. It’s extremely easy to create dynamic components to reuse them in every web application. I can’t say much about ASP, because I just started to use it, but the first impression of it was just mind-blowing.
The problems of JSP
There are more or less two groups of people (hmm, starts like one of those geek jokes…), those who love JSP and those who hate JSP. JSP is in fact really future rich, which makes it a really powerful environment but it runs rather slowly. If you want to run JSP you will probably need your own server, because I don’t know any shared web hoster which supports JSP due the large amount of resources JSP uses.
PHP is widely spread
You can probably do everything with PHP that JSP can do if you have the knowledge. One of the main features of PHP is that it was originally designed for the web and only for the web. JSP was created from Java, which is an extremely important and powerful language nowadays. I would say it’s easier to learn PHP than Java, so I think it really makes sense to use JSP if you already know Java, but want to create some web applications now. A really cool part is that you can reuse some of your algorithms again. For all the other people who start directly from the ground, I would really recommend PHP.
ASP what can I say…
ASP is a really cool language especially because you can combine it with all the .NET languages, which makes it really powerful. The reasons are almost the same as for JSP. There are not a lot of web hosters, which allow you to use ASP pages. The advantage of ASP compared with JSP is definitely the speed.
Other languages
There are also other languages like Perl or Ruby, but I have actually never used them so far.
Conclusion
As we can see there are so many different ways to create a web application which makes it really fun. I would say everyone should choose the language he/she prefers, because all of them do their job. It just really depends on what you really want to do and which basics and capabilities you have. It’s a fact that hosting PHP sites is much cheaper than hosting ASP or JSP sites. Which is a main feature for almost all the private webmasters.
Popularity: 100% [?]
Tags: .NET, ASP, ASP.NET, C#, Development, Java, JSP, PHP, Web Applications