ICEfaces-EE
  1. ICEfaces-EE
  2. IPCK-127

ICEfaces 2.0 composite components "id" attribute being injected into the page instead of passed through

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Invalid
    • Affects Version/s: None
    • Fix Version/s: EE-3.0.0.GA
    • Component/s: Facelet Components
    • Labels:
      None
    • Environment:
      ICEfaces 2.0 Beta 1, JSF 2.0.3, Glassfish 3.0.1, JDK 6.x

      Description

      When using a JSF 2.0 composite component that has an "id" attribute, the id will be rendered into the page instead of just passed through to the component. For example:

      <div id="parentCon">
       <ice-cc:filterTable id="ourTable" bean="..."/>
      </div>

      Then the component code itself:

      ...
      <ice:dataTable id="#{cc.attrs.id}"...
      ...

      We would expect the id of the composite component dataTable to be "parentCon:ourTable". Instead it appears to render as "parentCon:ourTable:ourTable", because the id of the filterTable composite component is being rendered into the page as well. Basically "id" looks like a reserved name that can't be freely used as a composite component attribute.

      To workaround you could use a different attribute name, for example 'fakeId="ourTable"' would properly render in the above example as "parentCon:ourTable". This breaks backwards compatibility and is more confusing for a user to work with.

      Also note this issue causes problems for components that rely on id, such as the "for" of a dataPaginator.

        Activity

        There are no subversion log entries for this issue yet.

          People

          • Assignee:
            Patrick Corless
            Reporter:
            Carlo Guglielmin
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: