Renders an HTML <form> element whose contents are described by the body content of this tag. The form implicitly interacts with the specified request scope or session scope data to populate the input fields with the current property values.
Attributes |
Name | Required | Request-time | Type | Description |
action | false | true | java.lang.String | The URL to which this form will be submitted. If a value is not provided, the original URI (servletPath) for the request is used. |
acceptCharset | false | true | java.lang.String | The list of character encodings for input data that the server should accept. - Since:
- Struts 1.2.2
|
disabled | false | true | boolean | Set to true if the Form's input fields should be disabled. - Since:
- Struts 1.2.7
|
enctype | false | true | java.lang.String | The content encoding to be used to submit this form, if the method is POST. This must be set to "multipart/form-data" if you are using the file tag to enable file upload. If not specified, the browser default (normally "application/x-www-form-urlencoded") is used. |
focus | false | true | java.lang.String | The field name (among the fields on this form) to which initial focus will be assigned with a JavaScript function. If not specified, no special JavaScript for this purpose will be rendered. |
focusIndex | false | true | java.lang.String | If the focus field is a field array, such as a radio button group, you can specify the index in the array to receive focus. - Since:
- Struts 1.1
|
method | false | true | java.lang.String | The HTTP method that will be used to submit this request (GET, POST). [POST] |
onreset | false | true | java.lang.String | JavaScript event handler executed if the form is reset. |
onsubmit | false | true | java.lang.String | JavaScript event handler executed if the form is submitted. |
readonly | false | true | boolean | Set to true if the Form's input fields should be read only. - Since:
- Struts 1.2.7
|
scriptLanguage | false | true | boolean | The form's focus <script> element will not contain a language attribute when this is set to false. The default is true but this property is ignored in XHMTL mode. - Since:
- Struts 1.2
|
style | false | true | java.lang.String | CSS styles to be applied to this HTML element. |
styleClass | false | true | java.lang.String | CSS stylesheet class to be applied to this HTML element (renders a "class" attribute). |
styleId | false | true | java.lang.String | Identifier to be assigned to this HTML element (renders an "id" attribute). |
target | false | true | java.lang.String | Window target to which this form is submitted, such as for use in framed presentations. |
name | false | false | string | Form name, used to reference the form in the Javascript checks. |
usetransactiontoken | false | false | boolean | Set to generate a hidden input field containing transaction token value. |