But is this the way a JSP calling EJB?
the examples is just a JB, not EJB
On Fri, 23 Nov 2001, Ludovic Maitre wrote:
> you can instantiate a bean from a JSP page with the jsp:use-bean
> statements as mentionned in the example packaged with tomcat 4 (and 3).
> For more informations read the fine manual or specification of JSP on
> the Sun website (their tutorial are also very good).
>
> in tomcat 4, file webapps/examples/jsp/checkbox/checkresult :
>
> <%! String[] fruits; %>
> <jsp:useBean id="foo" scope="page" class="checkbox.CheckTest" />
>
> <jsp:setProperty name="foo" property="fruit" param="fruit" />
> <hr>
> The checked fruits (got using request) are: <br>
> <%
> fruits = request.getParameterValues("fruit");
> %>
> <ul>
> <%
> if (fruits != null) {
> for (int i = 0; i < fruits.length; i++) {
> %>
> ...
>
> regards,
> Ludovic.
>
> Huaxin wrote:
> >
> > A little bit off topic, sorry about that.
> >
> > I see most of the examples using EJB from Servlet.
> > However, is there any example of using JSP with
> > EJB directly? (without too much scriplet, and
> > hopefully more efficient than create a bean to
> > interact with the EJB)
> >
> > thanks a lot
>
> --
> [EMAIL PROTECTED]
>
> INRIA - 2004 route des lucioles - BP 93 Tel: (33/0) 4 92 38 50 41
> 06902 SOPHIA-ANTIPOLIS cedex (France) Fax: (33/0) 4 92 38 76 02
>
> --
> To unsubscribe: <mailto:[EMAIL PROTECTED]>
> For additional commands: <mailto:[EMAIL PROTECTED]>
> Troubles with the list: <mailto:[EMAIL PROTECTED]>
>
--
To unsubscribe: <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>