netui:error Tag

<netui:error> Tag

Renders an error message with a given error key value if that key can be found in the ActionErrors registered in the PageContext at org.apache.struts.action.Action.ERROR_KEY.

Syntax

<netui:error
    [bundle="string_bundle"]
    [locale="string_locale"]
    [value="string_or_expression_value"] />

Description

Renders an error message with a given error key value if that key can be found in the ActionErrors registered in the PageContext at org.apache.struts.action.Action.ERROR_KEY.

The following optional message keys will be utilized if corresponding messages exist for them in the application resources:

Attributes

bundleThe message bundle where the error message can be found
 
RequiredSupports runtime expression evaluationData bindable
NoNoNo

localeThe session attribute key for the locale
 
RequiredSupports runtime expression evaluationData bindable
NoNoNo

valueThe value for getting the error key
 
RequiredSupports runtime expression evaluationData bindable
NoYesRead Only

Sample

In this sample, the "InvalidName" message from the errorMessages bundle will be used to output the error.
 <netui:error bundle="com.project.errorMessages" value="InvalidName"/>

Code Sample

[BEA_HOME]/weblogic81/samples/workshop/SamplesApp/WebApp/struts/validation/basic/formPage.jsp [BEA_HOME]/weblogic81/samples/workshop/SamplesApp/WebApp/struts/validation/validator/formPage.jsp

Related Topics

Form Validation Sample

<netui:errors> Tag