First off ANY time you can seperate your backend code and your front end display its well worth taking the time! That way if you have a major design change you arent spending days, weeks and months trying to redo all your servlets and how they present the data!

I always recommend using external styles for formatting and external script files for any javascript you may need. Saves a lot of headaches!

A servlet simply creates a text buffer that gets sent to the browser. There's nothing to prevent you from including Javascript, HTML or the Gettysburg Address in that text.

Even this person "u", whoever that is, can do it.

But generally, formatting an HTML page (including any Javascript) is best performed in a JSP rather than maintaining markup built up in string buffers. [ July 28, 2005: Message edited by: Bear Bibeault ]