This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
i need to skip jsf validation phase during the click of reset button in my jsp. Using "immediate=true", skips the validation well and good. But the problem here is, its not resetting the other values in the jsp.
Say, in the jsp there are totally 4 text fields for searching, now user has entered a special symbol in one of the text box and clicked on submit, now jsf validation runs and shows "Please enter a valid String".
At the same time if the user enters any special symbol and clicks on reset, now reset method is called, but the reset value of all the 4 text fields is not reflecting in the jsp(where i m setting the values back to null inside the reset() )
JSF is designed with the idea that the default handling of input data errors is to fail validation, which bypasses the backing bean updates and execution of the action method. re-rendering the page using the data values that were entered by the user. Normally, there will be error messages (validation messages) presented on the updated page (assuming you coded a place(s) to display them!). Thus, a screen print of the page shows what was mis-keyed and what the complaint was. Erasing the mis-keyed values could not only lead to confusion, but depending on the length and complexity of the input data could truly be annoying. More so, if you reset the entire form and not just the offending fields.
The JSF RESET control renders the low-level HTML RESET control. This object is wired directly to code in the client (browser) that replaces the input values in the form to the values they had when the page was displayed and is done without any interaction with the server whatsoever.
Customer surveys are for companies who didn't pay proper attention to begin with.