Article Index
10 Easy Ways to Promote Your Website
5 Simple Steps to Accepting Payments
5 Steps to Understanding HTML
5 Ways to Avoid the 1998 Look
6 Reasons Why You Need a Website
7 Ways to Make Your Web Forms Better
A Question of Scroll Bars
Ads Under the Radar Linking to Affiliates
AJAX Should You Believe the Hype
All About Design Principles and Elements
An Introduction to Paint Shop Pro
An Issue of Width the Resolution Problem
Avoiding the Nuts and Bolts Content Management Software
Beware the Stock Photographer Picking Your Pictures
Building a Budget Website
Building Online Communities
Clean Page Structure Headings and Lists
ColdFusion Quicker Scripting at a Price
Column Designs with CSS
Content is King
CSS and the End of Tables
Cut to the Chase How to Make Your Website Load Faster
Designing for Sales
Designing for Search Engines
Dont Be Scared Its Only Code HTML for Beginners
Dreamweaver The Professional Touch
Encryption and Security with SSL
Finding a Good HTML Editor
Focus on the User Task Oriented Websites
Fonts are More Important Than You Think
Free Graphics Alternatives
FrontPage Easy Pages
Hints All the Way
Hiring Professionals 5 Things to Look For
How Databases Work
How the Web Works
How to Get Your Website Talked About on Blogs
How to Install and Configure a Forum
How to Make Visitors Add You to Their Favorites
How to Run Ads Without Driving Visitors Crazy
How to Set Up Your Hosting in 5 Minutes Flat
IIS and ASP Microsofts Server
Image Formats GIF JPEG PNG and More
Its a World Wide Web Going International
JSP Java on Your Server
LAMP The Most Popular Server System Ever
Making Friends and Influencing People the Importance of Links
Making Searches Simple
Offering Free Downloads on Your Website
Opening a Web Shop with E Commerce Software
Perl Cryptic Power
Photoshop a Graphic Designers Dream
PHP Easy Dynamic Websites
Picking a Colour Scheme
Printing and Sending the Two Things Users Want to Do
Putting Multimedia to Good Use
Python and Ruby the Newer Alternatives
Registering a Domain Name
Registering Your Users by Stealth
RSS Really Simple Syndication
Setting Up a Mailing List
Setting up a Test Server on Your Own Computer
Some Places to Go For More Information
Taking HTML Further with Javascript
Taking HTML Further
Taking Your Website Mobile
Text Ads Unobtrusive Advertising
The 5 Principles of Effective Navigation
The Art of the Logo
The Basics of Web Forms
The Basics of Web Servers
The Case Against Flash
The Confusing World of Web Hosting Making Your Decision
The Evils of PDFs
The Importance of Validation
The Many Flavours of HTML
The Smaller the Better Avoiding Graphical Overload
The Top 10 Biggest Web Design Mistakes
The Web Designers Toolbox
The Web is Not Paper
Theres More than One Web Browser
Time for User Testing
Titles and Headlines Its Not a Newspaper
Tracking Your Visitors
Understanding Web Jargon
Uploading Your Website with FTP
Using Flash Sensibly
Using Quizzes and Games to Get Traffic
VBScript Javascript Made Easy
Websites and Weblogs Whats the Difference
What Do You Want Your Website to Do
What You See Isnt Always What You Get
Which Database is Right for You
Why Doing It Yourself is Best
Why Java Will Drive Your Visitors Away
Why Word is Bad for the Web
Why You Should Put Your Content in a Weblog Format
Why You Should Stick to Design Conventions
Working With Templates
Writing for the Web

JSP Java on Your Server

JSP: Java on Your Server.

JSP stands for Java Server Pages. The idea of JSP is to allow Java code to be embedded in HTML – this is done uising XML tags. JSP allows you to dynamically add content to your pages, and also offers the facility to send Java to the web browser easily.

The Lack of Functions.

Most of the built-in JSP functions do nothing more than flow control: it barely offers any built-in functions at all. Instead, you have to define your own tags using tag libraries. This makes the language extremely extensible, but not much use if you just want to get started quickly and write a simple database-driven website.

The most significant reason to use JSP is that it gives you all the power of Java when it comes to adding things to your HTML pages. In big companies especially, these Java capabilities are very important. The flexibility of the language is also very useful for larger projects: in some ways, JSP is more like a 'build your own programming language kit' than it is a language in itself.

Separating the Application Logic.

The real point of JSP is to separate out your application's logic (the part that does things) from its presentation (the HTML). JSP is, basically, a very minimal language intended to do little more than help turn the output of a Java application into a web page. This has the advantage of letting you write an entirely new website using your existing application as the backend – but it has the disadvantage that it can be difficult to add any new functions to the site unless you know what you're doing in Java.

Unfortunately, the downside of doing things this way is that, if you're not strict about it, HTML code will have a tendency to start creeping into the output of the backend Java application. If that happens, it will make it difficult to rewrite your JSPs without ending up with broken web pages.

Is Java a Good Idea?

One of the advantages of JSP is that it can easily take Java applets and throw them onto the web. When it comes down to it, though, Java isn't usually a good idea. Why? Well, it takes a long time to load, it's slow when it does load, and it doesn't tend to do anything that couldn't have been done better in Flash or even in plain old HTML. On the web, Java has come to be considered harmful.

On the server, though, Java is a fine idea, at least if you're good enough to program in it. There are simpler languages out there, but Java is cross-platform, standardised and does pretty much everything you could want it to. You will, though, need a pretty powerful server to use Java for any significant number of requests.

JSP or ASP?

JSP is obviously named to point out the fact that it is an alternative to Microsoft's ASP. So why would you use one instead of the other. Well, while ASP has the simplicity of Visual Basic on its side, JSP has the power of Java, and, more importantly, its cross-platform capabilities. While ASP will tie you down to a Microsoft platform, JSP can be used on any operating system capable of running Java – and that's just about all of them.

JSP or ColdFusion?

What JSP and ColdFusion have in common is that they can both interact with Java – but which is better? For most projects, the answer is ColdFusion: if you're building something relatively small (meaning non-enterprise), ColdFusion's built-in functions should be sufficient and the code shouldn't be able to grow so large as to be unmanageable.

Should JSP Stay in the Enterprise?

People with small website usually fall into one of two camps: the vendor-devoted people who are quite happy to run their whole system on Microsoft or Macromedia products because it saves them time, and the open source devotees who use languages like PHP because it saves them money and they support the principles involved. Among these two camps, there isn't really much room for JSP, and in most cases, there shouldn't be. Unless you're building a project that's larger than the average, or you've already got a Java application you want to write a web interface for, you'll probably be better off giving JSP a miss.