Subject: RE: XSLT vs JSP
From: "Don Park" <donpark@xxxxxxxxx>
Date: Sat, 26 Jun 1999 22:49:15 -0700
> I don't think it's silly at all and nothing like the
> analogies you give. My
> concern was that JSPs go 95% of the way towards being XML
> (with the benefits
> that brings) and then ruin any chance of that by using their
> own non-XML
> syntax extension.
> But if JSP has an XML encoding (of which I was not aware)
> then it makes me
> feel much better about it.

While I don't think it is silly, XML developers should take care not to fall
into 'everything should be XML' pitfall.  There are many reasons why JSP is
so similar to XML yet fails to be XML completely.

First reason is parsing speed.  It is easier and faster to search for <% and
%> than to parse all the tags as in XML.

Second reason is output format.  JSP is primarily designed to output HTML
which is different enough from XML to be problematic.  Forcing JSP to be XML
also causes static parts of JSP to be XHTML.

Third reason is ease of writing.  JSP can be created by simply copying some
HTML fragments over and then adding some Java or JavaScript code.  If JSP
was XML then reserved characters (i.e. <, >, &) will have to be escaped and
end tags have to be added (i.e. <p>).

It is true that JSP can be XML but I don't think it should be XML.  Matter
fact, XML sucks in many ways.  For example, my son prefers Pokeymon over
XML.  Maybe if I change his middle name to XML, he might change his opinion.


Don Park

 XSL-List info and archive:

Current Thread