In doing some other work on the Tiles tags, I found some problems with how
the PutListTag is implemented.

I fixed these (SVN revision r495431 and r495722, see also
http://svn.apache.org/viewvc/tiles/trunk/tiles-core/src/main/java/org/apache/tiles/taglib/PutListTag.java?view=log
)

I didn't build a new snapshot, because these changes also involved changing
the names of some of the tags and committers were not 100% united that the
changes were correct.
(see
http://www.nabble.com/-Tiles2--JSTL-functions-for-Tiles-taglib--t2961079.html
)

If you build from SVN and change some JSP tag names, you will probably be
ok, although I am not a regular user of the PutList tag; I just found these
issues while working on the rename and testing the changes.

Questions about unreleased code like Tiles2 are generally better aimed at
the struts-dev list (or, now, the recently created [EMAIL PROTECTED]).

I'll stir things up over there and see if people are game for a new SNAPSHOT
build based on those changes.

Joe

On 1/25/07, amboss <[EMAIL PROTECTED]> wrote:

Hi,

I have problem using putList tag on jsp page. Namely I`m trying to use
definition that looks like this:
  <definition name="tilestest.layout.list" template="/listLayout.jsp">
    <putList name="testlist">
        <add value="listItem0" type="string"/>
        <add value="listItem1" type="string"/>
        <add value="listItem2" type="string"/>
    </putList>
  </definition>
On a page whose contains code:
<tiles:insertDefinition name="tilestest.layout.list">
    <tiles:putList name="testList">
        <tiles:add value="item_00" type="string"/>
        <tiles:add value="item_01" type="string"/>
        <tiles:add value="item_02" type="string"/>
        <tiles:add value="item_03" type="string"/>
        <tiles:add value="item_04" type="string"/>
    </tiles:putList>
</tiles:insertDefinition>
Unfortunately this cause some problems which results in exception in jboss
logs.
org.apache.jasper.JasperException caused by:
java.lang.NullPointerException
org.apache.tiles.taglib.PutListTag.release(PutListTag.java:60)
org.apache.jasper.runtime.TagHandlerPool.release(TagHandlerPool.java:146)

Layout page looks like:
<tiles:importAttribute name="testlist"/>
<ul>
    <c:forEach var="item" items="${testlist}">
        <li><c:out value="${item}" /></li>
    </c:forEach>
</ul>

This problem occurs only when I`m trying to change values on the list in
the jsp page. It works just fine when I`m using values form the definition
in xml or I use  my own ViewPreparer to change default values.

Could you please help me with this issue?

I`m using tiles2 snapshot on jboss-4.0.3SP1 with java 1.5.0_6 on Linux
box.

--
Best regards,

Piotr

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--
Joe Germuska
[EMAIL PROTECTED] * http://blog.germuska.com

"The truth is that we learned from João forever to be out of tune."
-- Caetano Veloso

Reply via email to