tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Luis Andrei Cobo" <va...@megapathdsl.net>
Subject RE: javabeans + jsp
Date Thu, 14 Sep 2000 19:29:10 GMT
not necessarily have to be in WEB-INF, but so long as they are visible in
your classpath

in my case I have a few packages, each for different types of classes, one
package just for beans.I can keep them all in WEB-INF if I have class
reloading ON, but its not all the crucial in production time to keep them in
WEB-INF, simply reference them like so:
<jsp:useBean id="myBean" scope="session" class="com.business.beans.myBean"/>

lets be fair to WEB-INF....its not a toy  =)

Luis




-----Original Message-----
From: Rui Oliveira [mailto:oliveira@milu.ipn.pt]
Sent: Thursday, September 14, 2000 1:32 PM
To: tomcat-user@jakarta.apache.org
Subject: Re: javabeans + jsp


Yeps...

Java beans are classes that you must put under your context's
web-inf/classes
directory.. and you access them by doing the following:

Declaring the bean to use:
<jsp:useBean id="myBean" scope="page" class="myBeanClass" />

Using the bean:
<% String value = myBean.getValue(); %>


Regards

Rui Oliveira

On Thu, 14 Sep 2000 18:16:08 +0100 (BST)
Osvaldo Brito <osvaldo@laplace.inesc.pt> wrote:

> Does anyone have an idea about how does work javabeans with jsp.
> Thanks in advance.
>
> Osvaldo Brito
>
>
>
>
>


Mime
View raw message