When writing anycode, but this is especially true of JSP, you should try and
separate Logic from Content. To this end you shouldn't out Java code on a
JSP page (or at least minimize the amount of code there). This is one of the
reasons we have beans - to encapsualte the logic that the JSP needs.
There have been many, many discussions of this on the list - read the
archives for those,
Kevin Jones
DevelopMentor
www.develop.com
> -----Original Message-----
> From: A mailing list about Java Server Pages specification and reference
> [mailto:[EMAIL PROTECTED]]On Behalf Of babita malani
> Sent: 07 March 2000 06:53
> To: [EMAIL PROTECTED]
> Subject: bean or java code
>
>
> hello everybody,
>
> i have question,
>
> i have made a bean, and used it in a jsp.
> then i made another jsp in which i put java code for get the functionality
> provided by
> the bean in the previous page.
> both worked well.
>
> Now my question is, which way of doing things is better and why?
> what i presume is that second one is better , as it would be faster, since
> bean does not
> have to be searched and all.
>
> am i right ?
> if anybody has any suggestions for this , please do send them.
>
> regards
> Babita
> ______________________________________________________
> Get Your Private, Free Email at http://www.hotmail.com
>
> ==================================================================
> =========
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> JSP-INTEREST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets