users@jersey.java.net

jsp:include problem

From: Cheng Zhang <zhangyongjiang_at_yahoo.com>
Date: Sat, 22 Aug 2009 20:04:55 -0700 (PDT)

Hi,

I took the bookstore example and changed the index.jsp for class Bookstore as below,

change:
        <c:forEach var="i" items="${it.items}">
            <li><a href="items/${i.key}">${i.value.title}</a>
        </c:forEach>

to:

        <c:forEach var="i" items="${it.items}">
            <jsp:include page="/items/${i.key}"/>
        </c:forEach>

but got exception
    com.sun.jersey.api.container.ContainerException: java.io.FileNotFoundException: /bookstore/items/1

So is it possible to include another resource in the view of a particular resource? Or is there any workaround to achieve it?

Thanks a lot,
Kevin