That doesn't make much sense to me as generated IDs are in the form of
"_id##", so t2c is not possible unless you or some code explicitly sets it
somewhere. What JSF impl version are you using.

Also try grepping your code for t2c.

-Andrew

On Feb 5, 2008 4:38 PM, Łukasz Budnik <[EMAIL PROTECTED]> wrote:

> Hi,
>
> My view code is simply copy & paste from:
> http://www.irian.at/myfacesexamples/tree2.jsp.source
>
> and looks like this:
>
> <t:tree2 id="clientTree" value="#{Tree2TestController.treeData}"
> var="node" varNodeToggler="t">
>                    <f:facet name="person">
>                        <h:panelGroup>
>                            <f:facet name="expand">
>                                <t:graphicImage
> value="/images/tomahawk/yellow-folder-open.png"
> rendered="#{t.nodeExpanded}" border="0"/>
>                            </f:facet>
>                            <f:facet name="collapse">
>                                <t:graphicImage
> value="/images/tomahawk/yellow-folder-closed.png"
> rendered="#{!t.nodeExpanded}" border="0"/>
>                            </f:facet>
>                            <h:outputText value="#{node.description}"
> styleClass="nodeFolder"/>
>                        </h:panelGroup>
>                    </f:facet>
>                    <f:facet name="foo-folder">
>                        <h:panelGroup>
>                            <f:facet name="expand">
>                                <t:graphicImage
> value="/images/tomahawk/yellow-folder-open.png"
> rendered="#{t.nodeExpanded}" border="0"/>
>                            </f:facet>
>                            <f:facet name="collapse">
>                                <t:graphicImage
> value="/images/tomahawk/yellow-folder-closed.png"
> rendered="#{!t.nodeExpanded}" border="0"/>
>                            </f:facet>
>                            <h:outputText value="#{node.description}"
> styleClass="nodeFolder"/>
>                            <h:outputText value="
> (#{node.childCount})" styleClass="childCount" rendered="#{!empty
> node.children}"/>
>                        </h:panelGroup>
>                    </f:facet>
>                    <f:facet name="bar-folder">
>                        <h:panelGroup>
>                            <f:facet name="expand">
>                                <t:graphicImage
> value="/images/tomahawk/blue-folder-open.gif"
> rendered="#{t.nodeExpanded}" border="0"/>
>                            </f:facet>
>                            <f:facet name="collapse">
>                                <t:graphicImage
> value="/images/tomahawk/blue-folder-closed.png"
> rendered="#{!t.nodeExpanded}" border="0"/>
>                            </f:facet>
>                            <h:outputText value="#{node.description}"
> styleClass="nodeFolder"/>
>                            <h:outputText value="
> (#{node.childCount})" styleClass="childCount" rendered="#{!empty
> node.children}"/>
>                        </h:panelGroup>
>                    </f:facet>
>                    <f:facet name="document">
>                        <h:panelGroup>
>                            <h:commandLink immediate="true"
> styleClass="#{t.nodeSelected ? 'documentSelected':'document'}"
> actionListener="#{t.setNodeSelected}">
>                                <t:graphicImage
> value="/images/tomahawk/document.png" border="0"/>
>                                <h:outputText value="#{node.description}"/>
>                                <f:param name="docNum"
> value="#{node.identifier}"/>
>                            </h:commandLink>
>                        </h:panelGroup>
>                    </f:facet>
>                </t:tree2>
>
> best regards
> Łukasz
>
> On 05/02/2008, Andrew Robinson <[EMAIL PROTECTED]> wrote:
> > Where is the view code?
> >
> >
> > On Feb 5, 2008 12:08 PM, Łukasz Budnik <[EMAIL PROTECTED]> wrote:
> > > Sorry,
> > >
> > > this is full stack trace, the id treeForm:clientTree:t2c is repeated 3
> > > times (I have highlighted it):
> > >
> > >
> > > javax.servlet.ServletException: Component ID treeForm:clientTree:t2c
> > > has already been found in the view.  See below for details.
> > > +id: j_id_jsp_287013395_0
> > >  type: [EMAIL PROTECTED]
> > >  +id: treeForm
> > >   type: [EMAIL PROTECTED]
> > >    +id: clientTree
> > >     type: [EMAIL PROTECTED]
> > >
> > >      +id: j_id_jsp_287013395_17
> > >       type:
> > [EMAIL PROTECTED]
> > >
> > >        +id: j_id_jsp_287013395_18
> > >         type:
> > [EMAIL PROTECTED]
> > >
> > >        +id: j_id_jsp_287013395_19
> > >         type:
> > [EMAIL PROTECTED]
> > >        +id: j_id_jsp_287013395_20
> > >         type: [EMAIL PROTECTED]
> > >      +id: j_id_jsp_287013395_3
> > >       type:
> > [EMAIL PROTECTED]
> > >        +id: j_id_jsp_287013395_4
> > >         type:
> > [EMAIL PROTECTED]
> > >        +id: t2c
> > >         type:
> > [EMAIL PROTECTED]
> > >
> > > ^^^^^^^^^^^^^^
> > >
> > >        +id: j_id_jsp_287013395_6
> > >         type:
> > [EMAIL PROTECTED]
> > >      +id: j_id_jsp_287013395_12
> > >       type:
> > [EMAIL PROTECTED]
> > >        +id: j_id_jsp_287013395_13
> > >         type:
> > [EMAIL PROTECTED]
> > >        +id: t2c
> > >         type:
> > [EMAIL PROTECTED]
> > >
> > > ^^^^^^^^^^^^^^
> > >
> > >        +id: j_id_jsp_287013395_15
> > >         type:
> > [EMAIL PROTECTED]
> > >        +id: j_id_jsp_287013395_16
> > >         type:
> > [EMAIL PROTECTED]
> > >      +id: j_id_jsp_287013395_7
> > >       type:
> > [EMAIL PROTECTED]
> > >        +id: j_id_jsp_287013395_8
> > >         type:
> > [EMAIL PROTECTED]
> > >        +id: t2c
> > >         type:
> > [EMAIL PROTECTED]
> > >
> > > ^^^^^^^^^^^^^^
> > >
> > >        +id: j_id_jsp_287013395_10
> > >         type:
> > [EMAIL PROTECTED]
> > >        +id: j_id_jsp_287013395_11
> > >         type:
> > [EMAIL PROTECTED]
> > >
> > >
> > javax.faces.webapp.FacesServlet.service(FacesServlet.java:256)
> > >
> > org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(
> ExtensionsFilter.java:147)
> > >
> > org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(
> MonitorFilter.java:390)
> > >
> > > best regards
> > > Łukasz
> > >
> > >
> > >
> > >
> > > On 05/02/2008, Andrew Robinson <[EMAIL PROTECTED]> wrote:
> > > > No this is right. Component IDs in "looping" components should
> always be
> > the
> > > > same. Client IDs change.
> > > >
> > > > Your example doesn't show t2c at all. Look for two components it
> your
> > page
> > > > that are under the tree and have t2c as their ID. Maybe you thought
> that
> > two
> > > > components could have the same ID in different facets?
> > > >
> > > >
> > > > On Feb 5, 2008 10:54 AM, Łukasz Budnik <[EMAIL PROTECTED]>
> wrote:
> > > > > Hi All,
> > > > >
> > > > > I'm running a <t:tree2 /> example available at:
> > > > > http://www.irian.at/myfacesexamples/tree2.jsf
> > > > >
> > > > > And the result is:
> > > > >
> > > > > javax.servlet.ServletException: Component ID
> treeForm:clientTree:t2c
> > > > > has already been found in the view.  See below for details.
> > > > > +id: j_id_jsp_287013395_0
> > > > >  type: [EMAIL PROTECTED]
> > > > >  +id: treeForm
> > > > >   type: [EMAIL PROTECTED]
> > > > >    +id: clientTree
> > > > >     type:
> > > > [EMAIL PROTECTED]
> > > > >      +id: j_id_jsp_287013395_17
> > > > >       type:
> > > > [EMAIL PROTECTED]
> > > > >        +id: j_id_jsp_287013395_18
> > > > >         type:
> > > > [EMAIL PROTECTED]
> > > > >          +id: j_id_jsp_287013395_19
> > > > >           type:
> > > >
> > [EMAIL PROTECTED]
> > > > >
> > > > > ... and so on
> > > > >
> > > > > the only id that I have set in my tree.jsp are:
> > > > >
> > > > >
> > > > > <h:form id="treeForm">
> > > > >  <t:tree2 id="clientTree" value="#{Tree2TestController.treeData}"
> > > > > var="node" varNodeToggler="t">
> > > > >
> > > > > ...
> > > > >
> > > > > the rest is simply copy and paste from the above mentioned web
> site.
> > > > >
> > > > > I'm using:
> > > > >
> > > > > myfaces-shared-tomahawk-3.0.1
> > > > > tomahawk-1.1.7-SNAPSHOT
> > > > >
> > > > > since all ids should be unique clearly this is... a bug?
> > > > >
> > > > > best regards
> > > > > Łukasz
> > > > >
> > > >
> > > >
> > >
> >
> >
>

Reply via email to