jsf icefaces basic problem with displaying value
- by michal
Hi All, I don't know what I'm doing wrong.I'm using icefaces and have basic controller:
public class TestingController {
private String name;
public String submit() {
setName("newName");
return null;
}
public void setName(String name) { this.name = name;}
public String getName() { return name; }
}
--------and view:
<ice:inputText id="inp" value="#{testController.name}" /> <br>
<ice:commandButton id="submit" value="SUBMIT" action="#{testController.submit}" />
When I submit the form after first displaying the page..the input is set to newName, next I clear the inputText to "". and submit again but the name is not set to newName again as I would expect but it's empty.
thank you in advance for you help.