Dynamically assigning IDs to tags using an EL variable
问题 I want to loop over a number of "guests" and insert an id dynanimally <ui:repeat value="#{guestList}" var="guest"> <p:inputText id="firstname_#{guest.uniqueID}" value="" label="Firstname" /> <p:message for="firstname_#{guest.uniqueID}" /> </ui:repeat> The problem is, that the <p:message /> cannot resolve firstname_#{guest.uniqueID} javax.faces.FacesException - Cannot find component "firstname_1" in view. at org.primefaces.component.message.MessageRenderer.encodeEnd(MessageRenderer.java:41) It