1 Reply Latest reply on May 31, 2009 7:36 AM by Hans Kristanto

    Trigger Effect after a bean value

    Hans Kristanto Newbie

      Hai guys,

      i'm newbie in RichFaces. There are several question i want to ask :

      1. I want to create a simple application. I have a form to login. what i need is, if a button is pressed, then there's an <h:outputText> that the value will be "Authenticating...". After it's authenticated, then the value will be "You are login!". Otherwise, the value will be "You are not authorized!"

      2. Similar question with number one, but once the user is not authorized, than there will be an effect appear with message "You are not authorized". Otherwise, the page will be redirected. What should i do?

      my code is :

       <rich:panel style="width:21%;">
       <f:facet name="header">
       <h:outputText value="Marcapada Login"></h:outputText>
       </f:facet>
       <h:panelGrid columns="2">
       <h:outputText value="Name "/>
       <h:inputText id="uname" value="#{UserLogin.uname}"/>
       <a4j:commandButton value="Login" reRender="inv"/>
       </h:panelGrid>
       </rich:panel>
       <h:panelGrid columns="2">
       <h:outputText id="inv"/>
       </h:panelGrid>
      


      where the outputText with id "inv" will be the panel that will show authentication message and effect.

      i really need this script. Thank you very much for any clue or guidance!