In this section, we will demonstrate how to use the AutoComplete feature with InputTextarea and show how many more characters can be entered into that field, which is shown as follows:
Create the user account form with
<p:inputTextarea>
to enter the user's biography:<h:form id="myAccountForm"> <p:panel header="My Account"> <h:panelGrid columns="2"> <p:outputLabel for="bio" value="About Me"/> <p:inputTextarea id="bio" value="#{userController.loginUser.bio}" cols="50" rows="5" completeMethod="#{userController.completeBio}" minQueryLength="4" scrollHeight="100" counter="counter" counterTemplate="{0} characters remaining" maxlength="500" autoResize="true" /> <h:outputText id="counter" value="" /> <p:commandButton value="save" actionListener="#{userController.updateUser}" update="@form"/> </h:panelGrid> </p:panel...