0 Replies Latest reply on May 16, 2011 12:58 AM by Ging Ming Chan

    rich:tabPanel and c:forEach

    Ging Ming Chan Newbie

      Hi,

       

      I know this question has been asked several times, and we need to use c:forEach with dynamical rich:tab.  But my problem is that with c:forEach, the variable properties are not printed out.  I'm using Richfaces 3.3.3 + Seam 2.2.1 + Facelets.

       

       

      {code:xml}

      <rich:tabPanel switchType="client">

           <rich:tab label="test">

                <c:forEach items="#{serviceProvider.facilityList}" var="facility" varStatus="loop">

                     #{facility.label}

                </c:forEach>

       

                <ui:repeat var="facility1" value="#{serviceProvider.facilityList}">

                     #{facility1.label}

                </ui:repeat>

           </rich:tab>

       

           <c:forEach items="#{serviceProvider.facilityList}" var="facility" varStatus="loop">

                <rich:tab label="#{facility.label}">

                     Test

                </rich:tab>

           </c:forEach>

      </rich:tabPanel>

      {code}

       

      The code inside the c:forEach doesn't work.  In those part, the #{facility.label} does not print out anything.  However, the code under ui:repeat is working fine.

       

      Also the <rich:tab label="#{facility.label}"> does not contain any label.

       

      I read in a post that the person that encountered the same problem solved it by changing the namespace to

      http://java.sun.com/jsp/jstl/core.  I'm sure that I'm using the correct one: xmlns:c="http://java.sun.com/jsp/jstl/core" from jstl-1.2.jar.

       

      Another question is, what's the namespace "http://java.sun.com/jstl/core" refer to?  I saw that a lot of people is using the namespace without the "jsp" in the code example for dynamically creating rich:tab.  If I use that namespace, the tab does not gets created dynamically, it has no effect at all.

       

      Any help is really appreciated.