-
ASP vs JSP, Servlets vs WebClass
I am only a couple of months into Java so I hope I dont tread on any toes
here!
The problem as I see it is this: both ASP and JSP embed code in your HTML,
which makes it problematic to use tools such as Frontpage et al to redesign
the content or manage the site - managing large ASP/JSP sites becomes a real
headache.
Using Servlets or WebClasses to generate HTML from code is even uglier -
anyone trying to generate more than simple HTML from println statements is
going to lose a lot of hair.
I thought MS had come out with the perfect compromise in VB6/WebClasses with
their template system. Basically an HTML template was parsed by the WebClass
and matching tags were replaced by custom data/HTML or whatever and the result
sent to the browser. That way HTML stays (mostly) in the template, and code
stays in the application. Sadly I have yet to see this feature in the Java
world, so I have written my own parser servlets and am very happy with the
result. I can write my pages in Frontpage (or other HTML editor) putting
custom tags where I want my data to appear, then when the page is requested
the servlet scans it and substitutes the data, typically with fields from
persistent objects retrieved from a database.
Am I reinventing the wheel here? Has this already been done (probably better
too!) Anyone interested in this approach?
Rgds
Ewan
-
Re: ASP vs JSP, Servlets vs WebClass
Reinventing the wheel? Isn't that our way of life? But anyway, you may be
interested in an article entitled "Servlet Programming for Teams - How Java
programmers and HTML designers can collaborate using XML". It was at
http://developer.netscape.com/viewso...archal_xml.htm last October. It
starts out "This article presents a technique I developed for cleanly
separating the presentation aspect from the application logic in Java
servlets, to match the organization of most web site development teams into
HTML designers and Java developers." If you can't find it and want to see
it, contact me and I'll get a paper copy to you somehow.
Ewan Makepeace <ewan@ibm.net> wrote in message
news:38e1a726$1@news.devx.com...
>
> I am only a couple of months into Java so I hope I dont tread on any toes
> here!
> The problem as I see it is this: both ASP and JSP embed code in your HTML,
> which makes it problematic to use tools such as Frontpage et al to
redesign
> the content or manage the site - managing large ASP/JSP sites becomes a
real
> headache.
> Using Servlets or WebClasses to generate HTML from code is even uglier -
> anyone trying to generate more than simple HTML from println statements is
> going to lose a lot of hair.
> I thought MS had come out with the perfect compromise in VB6/WebClasses
with
> their template system. Basically an HTML template was parsed by the
WebClass
> and matching tags were replaced by custom data/HTML or whatever and the
result
> sent to the browser. That way HTML stays (mostly) in the template, and
code
> stays in the application. Sadly I have yet to see this feature in the Java
> world, so I have written my own parser servlets and am very happy with the
> result. I can write my pages in Frontpage (or other HTML editor) putting
> custom tags where I want my data to appear, then when the page is
requested
> the servlet scans it and substitutes the data, typically with fields from
> persistent objects retrieved from a database.
> Am I reinventing the wheel here? Has this already been done (probably
better
> too!) Anyone interested in this approach?
>
> Rgds
> Ewan
-
Re: ASP vs JSP, Servlets vs WebClass
read this
http://www.devx.com/upload/free/feat...jt0004/jt0004.
asp
jc
Ewan Makepeace <ewan@ibm.net> wrote in message
news:38e1a726$1@news.devx.com...
>
> I am only a couple of months into Java so I hope I dont tread on any toes
> here!
> The problem as I see it is this: both ASP and JSP embed code in your HTML,
> which makes it problematic to use tools such as Frontpage et al to
redesign
> the content or manage the site - managing large ASP/JSP sites becomes a
real
> headache.
> Using Servlets or WebClasses to generate HTML from code is even uglier -
> anyone trying to generate more than simple HTML from println statements is
> going to lose a lot of hair.
> I thought MS had come out with the perfect compromise in VB6/WebClasses
with
> their template system. Basically an HTML template was parsed by the
WebClass
> and matching tags were replaced by custom data/HTML or whatever and the
result
> sent to the browser. That way HTML stays (mostly) in the template, and
code
> stays in the application. Sadly I have yet to see this feature in the Java
> world, so I have written my own parser servlets and am very happy with the
> result. I can write my pages in Frontpage (or other HTML editor) putting
> custom tags where I want my data to appear, then when the page is
requested
> the servlet scans it and substitutes the data, typically with fields from
> persistent objects retrieved from a database.
> Am I reinventing the wheel here? Has this already been done (probably
better
> too!) Anyone interested in this approach?
>
> Rgds
> Ewan
-
Re: ASP vs JSP, Servlets vs WebClass
"Ewan Makepeace" <ewan@ibm.net> wrote:
>
>I am only a couple of months into Java so I hope I dont tread on any toes
>here!
>The problem as I see it is this: both ASP and JSP embed code in your HTML,
>which makes it problematic to use tools such as Frontpage et al to redesign
>the content or manage the site - managing large ASP/JSP sites becomes a
real
>headache.
>Using Servlets or WebClasses to generate HTML from code is even uglier -
>anyone trying to generate more than simple HTML from println statements
is
>going to lose a lot of hair.
>I thought MS had come out with the perfect compromise in VB6/WebClasses
with
>their template system. Basically an HTML template was parsed by the WebClass
>and matching tags were replaced by custom data/HTML or whatever and the
result
>sent to the browser. That way HTML stays (mostly) in the template, and code
>stays in the application. Sadly I have yet to see this feature in the Java
>world, so I have written my own parser servlets and am very happy with the
>result. I can write my pages in Frontpage (or other HTML editor) putting
>custom tags where I want my data to appear, then when the page is requested
>the servlet scans it and substitutes the data, typically with fields from
>persistent objects retrieved from a database.
>Am I reinventing the wheel here? Has this already been done (probably better
>too!) Anyone interested in this approach?
>
>Rgds
>Ewan
Ewan,
We've come up with the same concept. It is very much like the examples
of using macro code (JPython, etc.) instead of Java in the JSP's.
Have a look at http://www.servlets.com/soapbox/problems-jsp.html.
I didn't think having marco code in JSP's was much different than Java -
it is still code.
Mark
-
Re: ASP vs JSP, Servlets vs WebClass
Ewan--
Have a look at Enhydra Application Server. Same ideas (?) as your parser
servlets in open source Java.
http://www.enhydra.org/
-----------
Mark
markh@iwidgets.com
"Mark" <mknuttall@sprynet.com> wrote:
>
>"Ewan Makepeace" <ewan@ibm.net> wrote:
>>
>>I am only a couple of months into Java so I hope I dont tread on any toes
>>here!
>>The problem as I see it is this: both ASP and JSP embed code in your HTML,
>>which makes it problematic to use tools such as Frontpage et al to redesign
>>the content or manage the site - managing large ASP/JSP sites becomes a
>real
>>headache.
>>Using Servlets or WebClasses to generate HTML from code is even uglier
-
>>anyone trying to generate more than simple HTML from println statements
>is
>>going to lose a lot of hair.
>>I thought MS had come out with the perfect compromise in VB6/WebClasses
>with
>>their template system. Basically an HTML template was parsed by the WebClass
>>and matching tags were replaced by custom data/HTML or whatever and the
>result
>>sent to the browser. That way HTML stays (mostly) in the template, and
code
>>stays in the application. Sadly I have yet to see this feature in the Java
>>world, so I have written my own parser servlets and am very happy with
the
>>result. I can write my pages in Frontpage (or other HTML editor) putting
>>custom tags where I want my data to appear, then when the page is requested
>>the servlet scans it and substitutes the data, typically with fields from
>>persistent objects retrieved from a database.
>>Am I reinventing the wheel here? Has this already been done (probably better
>>too!) Anyone interested in this approach?
>>
>>Rgds
>>Ewan
>
>Ewan,
> We've come up with the same concept. It is very much like the examples
>of using macro code (JPython, etc.) instead of Java in the JSP's.
>
>Have a look at http://www.servlets.com/soapbox/problems-jsp.html.
>
>I didn't think having marco code in JSP's was much different than Java -
>it is still code.
>
>Mark
>
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks