i want update a bean property from the same jsf wo contains this bean property by getting the new value from a method inside this bean.
here is the jsf sample :
<h3>JSF Login Logout</h3>
<h:outputText value="Username" />
<h:inputText id="username" value="#{login.user}"></h:inputText>
<h:outputText value="Password" />
<h:inputSecret id="password" value="#{login.pwd}"></h:inputSecret>
<h:message for="password"></h:message>
<br /><br />
<h:commandButton action="#{login.validateUsernamePassword}"
value="Login"></h:commandButton>
here is the bean method :
//validate login
public String validateUsernamePassword() {
...
this.user = "admin";
...
}
i want return back to the same jsf and fill user field by the new value.