You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by bu...@apache.org on 2003/01/28 22:41:32 UTC
DO NOT REPLY [Bug 16514] New: -
Nested tiles fail in this release
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16514>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16514
Nested tiles fail in this release
Summary: Nested tiles fail in this release
Product: Struts
Version: 1.1 Beta 3
Platform: PC
OS/Version: Windows NT/2K
Status: NEW
Severity: Normal
Priority: Other
Component: Tiles framework
AssignedTo: struts-dev@jakarta.apache.org
ReportedBy: john@jazsoft.ca
Tiles nested in tiles fail in 1.1 Beta 3, but work in previous versions. In Beta
3, the layout is incorrect. This fails using both Tomcat 4.0.6 and JBoss 3.0.4
using the bundled Jetty JSP container.
eg.
First page defined as:
<%@ taglib uri="/tags/struts-bean" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-tiles.tld" prefix="tiles" %>
<tiles:insert definition="standardDefinition" flush="true" >
� <tiles:put name="title">Nested Tiles</tiles:put>
� <tiles:put name="body" value="/WEB-INF/jsp/content/NestedTiles.jsp" />
<tiles:put name="menu" type="string" value=" " />
</tiles:insert>
===================
/WEB-INF/jsp/content/NestedTiles.jsp defined as:
<%@ taglib uri="/tags/struts-bean" prefix="bean" %>
<%@ taglib uri="/tags/struts-html" prefix="html" %>
<%@ taglib uri="/tags/struts-logic" prefix="logic" %>
<%@ taglib uri="/WEB-INF/struts-tiles.tld" prefix="tiles" %>
<%
pageContext.setAttribute("formElementsSource",
"/WEB-INF/jsp/content/formElements/NestTiles.jsp");
%>
<html:form action="/Search?action=DoSearch" method="post">
<p>
<tiles:insert page="/WEB-INF/jsp/layout/searchFormLayout.jsp" flush="false" >
<tiles:put name="formElements" beanName="formElementsSource"
beanScope="page"/>
</tiles:insert>
<html:hidden property="infoType" value="Books"/>
<html:hidden property="searchType" value="library"/>
</html:form>
===================
/WEB-INF/jsp/layout/searchFormLayout.jsp defined as:
<%@ taglib uri="/WEB-INF/struts-tiles.tld" prefix="tiles" %>
<%@ taglib uri="/tags/struts-html" prefix="html" %>
<tiles:insert attribute="formElements"/>
========================
and /WEB-INF/jsp/content/formElements/NestTiles.jsp defined as:
<%@ taglib uri="/tags/struts-html" prefix="html" %>
<html:text property="searchTerm1" />
<html:submit value="Go" styleId="submit"/>
=======================
In previous versions, the generated HTML is correct.
In Beta 3, the following fragment is generated
....
<input type="text" name="searchTerm1" value="">
<input type="submit" value="Go" id="submit">
<form name="SearchForm" method="post"
action="/search/Search.do?action=DoSearch">
<p>
<input type="hidden" name="infoType" value="Books">
<input type="hidden" name="searchType" value="library">
</form>
....
As can be seen, the nested elements ("text" and "submit") are defined before the
form, and hence the form fails.
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>