2 Replies Latest reply on Oct 19, 2007 6:18 AM by Andrew Batman

    how to generate dynamic id of tag?

    Andrew Batman Newbie

      i have a list of commodities and want to generate id of <a:outputPanel> that corresponds to commodity.id . then i am going to rerender particular <a:outputPanel> with ajax, but not all of them.
      but #{currentCommodity.id} doesn't occur in result id :
      source:

      <a:repeat value="#{listCommodities.getCommodities()}" var="currentCommodity">
       <a:outputPanel id="#{currentCommodity.id}spinbox">
       #{currentCommodity.id}
       </a:outputPanel>
       </a:repeat>

      result html:
      <span id="j_id2:0:spinbox">450</span>
      <span id="j_id2:1:spinbox">451</span>
      <span id="j_id2:2:spinbox">550</span>
      <span id="j_id2:3:spinbox">601</span>
      <span id="j_id2:4:spinbox">500</span>