Tobago Demo

Menu

Required

If the validation of a form is activated and the actual value of this form is only stored temporarily, the validation is deactivated until the value is definitely stored into the model.

For example, if only the value in 'Inner Form 1' is set, the validation of the other forms are turned off.

Tag Library Documentation

Example

Every form in this example is surrounded by a content box. The submit buttons in the inner forms only put the inner value into the model. The submit button in the outer form put all values into the model. The validation for the inner value 2 and for the outer value is activated, both fields are required.

<tc:box label="Outer Form"> <tc:form> <tc:box label="Inner Form 1"> <tc:form> <tc:in label="Inner Value 1"/> <tc:out label="Inner Value 1 in Model"/> <tc:button label="Submit"/> </tc:form> </tc:box> <tc:box label="Inner Form 2"> ... </tc:box> <tc:separator/> <tc:in label="Outer Value" required="true"/> <tc:out label="Outer Value in Model"/> <tc:button label="Submit"/> </tc:form> </tc:box>

Outer Form

Inner Form 1

Inner Form 2


© 2005-2023 Apache Software Foundation, Licensed under the Apache License, Version 2.0.