1 Reply Latest reply on Sep 24, 2008 8:01 AM by Ilya Shaikovsky

    How to keep the togglePanel state.

    Thiagu Mariappan Novice

      Hai every one

      I need to get the user name from second state of the togglePanel.
      At the time of submitting the form if any validation error meant I need to keep open the second state, and I need to display the validation error.

      Here my problem is at the time of submitting the form togglePanel goes to the initial state.
      I don't know how keep open the second state if any validation error on that state.

      this is my sample code.

      <rich:togglePanel switchType="client" stateOrder="closed,submit">
       <f:facet name="closed">
       <rich:toggleControl value="Login"/>
       <f:facet name="submit">
       <h:messages style="color:red"/>
       <h:outputLabel for="username">Username :</h:outputLabel>
       <h:inputText id="username" value="#{uesr.username}" required="true"/>
       <h:commandButton value="submit" action="#{form.submit}"/>

      please any help