Hi,

I have a tile that reads items from a PutList list and then inserts each
item into the current page. 

   <struts_logic:iterate id="item" name="itemList" scope="page"
type="String">
       <tiles:insert name='<%=item%>' flush="true"/>
   </struts_logic:iterate>

When the items in the list are tiles defined in my tileDefinitions.xml file,
the tiles are inserted into my JSP correctly. However, I want to dynamically
create a tile definition and insert it into the page context. 

I am generating the ComponentDefinition in my tile controller and accessing
the "itemList" where I add the name of the dynamically generated definition:

      /* get the item list and insert new tile def into it */
      ArrayList itemList = (ArrayList)context.getAttribute("itemList");
      if (itemList != null) {

        HashMap map = new HashMap();
        map.put("name", "newtarget");
        map.put("link", "newtarget.do");
        
        ComponentDefinition newItem = 
                        new ComponentDefinition("new.item",
                                          "/mytiles/simpleItem.jsp",
                                                        map);

        DefinitionsUtil.setActionDefinition( request, breadCrumbItem );
        itemList.add("new.item");
      }

In my tile, the "itemList" contains the "new.item" entry, but it does not
appear to find the ComponentDefinition I created.

Thanks for you help.

Chris

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

Reply via email to