2 Replies Latest reply on Feb 7, 2010 1:26 PM by looseleaf

    custom component: using JSF core and JSF HTML in jspx-template

      Hi!

       

        Now that, with Nick Belaevski's help, we finally managed to use a <c:forEach> element in our custom component, I am again. I'd like to proved a HTML <select> element that's populated by a LinkedHashMap.

       

      In theory, this should work:

      {code:xml}<h:selectOneMenu id="#{clientId}selectT" value="#{component.attributes['valueT']}">
          <f:selectItems value="#{this:getTStatesMap(component)}" />
        </h:selectOneMenu>{xml}

       

      Practically, I don't get the <select> element rendered. I checked the namespace and found that h: anf f: are mapped to http://ajax4jsf.org/cdk/h and  http://ajax4jsf.org/cdk/template respectively.

       

      So I changed the cited markup to use jsfhtml: and jsfcore: prefixes and included

      {code:xml}xmlns:jsfcore="http://java.sun.com/jsf/core"

      xmlns:jsfhtml="http://java.sun.com/jsf/html"{code}

      in the header of our RichFaces template.

       

      Only, the <select> element is still not there. The source code of the rendered HTML page shows that obviously there's no resposible renderer found for the core and HTML namespaces because I find this:

       

      <jsfhtml:selectOneMenu id="form:tnmstatusselectT" value="0"><jsfcore:selectItems value="{0=Keine Anzeichen eines Primärtumors oder Primärtumor unbekannt., 1=T Stufe 1., 2=T Stufe 2., 3=T Stufe 3., 4=T Stufe 4., x=Keine Aussage über den Primärtumor möglich., is=Tumor in situ., a=Ta.}"></jsfcore:selectItems></jsfhtml:selectOneMenu>

       

      What am I missing? Thanks for pointers,

      Stefan