"Zhou, Bin, BGM" wrote:
> I can not agree more and I think the JSP might do better in this sense.
Of course, JSP tempts you to make the same "mistake" (IMHO) in reverse, by
embedded functional Java logic in your JSP page full of HTML code.
I have found that the best practice for my apps is to use pure servlets to
manage the business logic (acting as the "C" in MVC), storing the results in
beans, and forwarding control to an appropriate JSP page to display the
results. The only Java logic I use within JSP pages is solely related to
formatting (such as a "for" statement to iterate through an array while
generating table rows).
In the JSP 0.92 spec, this was called the "Model 2" application design
approach. JSP 1.0 calls it the "Redirecting Requests" model instead (Section
1.6.5 in JSP 1.0). This approach is well worth your time to study and apply.
>
> :-) Bin
> Bin Zhou
> *732-957-7692
> *[EMAIL PROTECTED]
>
Craig McClanahan
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html