<%@ page session="false" contentType="text/html;charset=utf-8" %> <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %> <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %> <%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t" %> <%@ taglib uri="http://myfaces.apache.org/sandbox" prefix="s" %> <%@ include file="inc/head.inc" %>

Ajax Form Components

The backend data model will update without having to click the submit button. To see error handling, put in some random text into the Fields.
It is possible to place one error message beneath each field or having one central place for displaying all messages.
In this case it may be useful to mark with the help of the errorStyleClass or errorStyle attribute of the ajax fields where the error have occured.


This component demonstrates ajax updating ability when you change the text.
An error message is displayed if the given String is greater than 5 characters.

This component demonstrates ajax updating ability, but you must click Ok for it to send.
Cancel will clear the text and not send an update. Will show a validation error if the string is less then 3 characters.

This component demonstrates error handling capabilities, enter an invalid string to see the error returned from the server through ajax.
This is the thomahawk messages component with forceRenderSpan set to true.
All messages which are generated by the inputTextAjax fields are displayed here.


This component demonstrates ajax updating ability on a checkboxes. This component demonstrates ajax updating ability on a radio buttons. This component demonstrates ajax updating ability based on a toggle switch. This component demonstrates ajax updating ability based on a toggle switch.
This component demonstrates submitting a form through ajax. To see validation errors, put less than five characters in first box, and a string with a space in it in the second box. <%-- Auto updating piece --%> Log:
<%@ include file="inc/page_footer.jsp" %>