[ http://issues.apache.org/struts/browse/SB-34?page=all ]
Work on SB-34 stopped by Antonio Petrelli. > <tiles:importAttribute> from putLIst returns ComponentAttribute instead of > List > ------------------------------------------------------------------------------- > > Key: SB-34 > URL: http://issues.apache.org/struts/browse/SB-34 > Project: Sandbox > Issue Type: Bug > Components: Tiles > Affects Versions: 2.0 > Environment: Mac OS X 10.4.7, Java SE 1.5.0_06, JBoss 4.0.4 GA EJB3, > JBoss Seam 1.0.1 GA, JSTL 1.1 > Reporter: Marcello Teodori > Assigned To: Antonio Petrelli > > when adding a list of attributes in a tiles definition with putList then when > I try to get the list of values from a JSP I get a ClassCastException. > Investigating further the returned object is of type ComponentAttribute, so I > had to get its "value" JavaBean attribute to iterate over it as a List, that > is: > <tiles:importAttribute name="stylesheets" ignore="true"/> > <c:forEach var="stylesheet" items="${stylesheets.value}"> > <link rel="stylesheet" type="text/css" media="all" > href="${pageContext.request.contextPath}/${stylesheet}" /> > </c:forEach> > while from the documentation in Struts Tiles I should have used > ${stylesheets} instead of ${stylesheets.value} -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/struts/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
