struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sri Sankaran" <>
Subject [TILES] Passing attributes to tiles
Date Tue, 25 Mar 2003 18:12:22 GMT
Using Struts 1.1b3

Consider a simple page layout comprised of two tiles, a body and a (wizard-like) navigation
bar.  I would like to conditionally disable certain navigational buttons on some pages.  I
am trying to use the <tiles:put> and <tiles:useAttribute> to no avail.

Here's a sample tile definition

<definition name="tile.1" path="tile-1.jsp">
  <put name="hideButton" value="yes"/>
  <put name="body" value="tile-1-body.jsp"/>
  <put name="nav" value="tile-1-nav.jsp"/>

I find that I can access "hideButton" in tile-1.jsp but not in tile-1-nav.jsp.  

In other words, the following works in tile-1.jsp


Hide value is <%=hide%>

But not in any of tile-1-body.jsp or tile-1-nav.jsp.

Is this expected behavior?  Do you have any suggestions on how I can achieve what I am trying?
 The one workaround I have is to use a <bean:define> in tile-1.jsp and reference that
bean in tile-1-nav.jsp.


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message