Difference between client id generated by component.clientId and p:component()
问题 I am trying to retrieve the client id of a h:panelGroup that is within a p:dataList. I tried 2 approaches: 1.Using component.clientId e.g: <h:panelGroup id="listItem"> <h:outputText value="#{component.clientId}" /> </h:panelGroup> 2.Using p:component() e.g: <h:panelGroup id="listItem"> <h:outputText value="#{p:component('listItem')}" /> </h:panelGroup> Please note that this panel group is within a datalist. Now, the client ids generates in both the cases is different. (1) does not have the