Fill-Out Forms (2024)

Table of Contents
TEXTAREA Permitted Attributes
Permitted Context: %Body.Content
Content Model: PCDATA (i.e. text and entities)

TEXTAREA

To let users enter more than one line of text, use the TEXTAREAelement. For example:

<TEXTAREA NAME="address" ROWS=64 COLS=6>HaL Computer Systems1315 Dell AvenueCampbell, California 95008</TEXTAREA>

The text up to the end tag is used to initialize the field's value.The initialization text can contain SGML entities, e.g. for accentedcharacters, but is otherwise treated as literal text. This end tag isalways required even if the field is initially blank. When submitting aform, the line terminators are implementation dependent. Servers shouldbe capable of recognizing a CR immediately followed by an LF, orseparate CRs and LFs as all signifying the ends of lines. User agentsshould tolerate the same range of line terminators within theinitialization text.

In a typical rendering, the ROWS and COLS attributes determine thevisible dimension of the field in characters. The field is rendered ina fixed-width font. User agents should allow text to grow beyond theselimits by scrolling as needed. The user agent is recommended to wrapwords as they are entered, to fit within the textarea field. It isfurther recommended that a means is provided for users to turn thisfeature off and on.

Note: In the initial design for forms, multi-line text fieldswere supported by the INPUT element with TYPE=TEXT. Unfortunately, thiscauses problems for fields with long text values as SGML limits thelength of attribute literals. The HTML 2.0 DTD allows for up to 1024characters (the SGML default is only 240 characters).

Permitted Attributes

ID
An SGML identifier used as the target for hypertextlinks or for naming particular elements in associated style sheets.Identifiers are NAME tokens and must be unique within the scope of thecurrent document.
LANG
This is one of the ISO standard language abbreviations,e.g. "en.uk" for the variation of English spoken in the United Kingdom.It can be used by parsers to select language specific choices forquotation marks, ligatures and hypenation rules etc. The languageattribute is composed from the two letter language code from ISO 639,optionally followed by a period and a two letter country code from ISO3166.
CLASS
This a space separated list of SGML NAME tokens and isused to subclass tag names. By convention, the classnames are interpreted hierarchically, with the most general class onthe left and the most specific on the right, where classes areseparated by a period. The CLASS attribute is most commonly used toattach a different style to some element, but it is recommended thatwhere practical class names should be picked on the basis of theelement's semantics, as this will permit other uses, such asrestricting search through documents by matching on element classnames. The conventions for choosing class names are outside the scopeof this specification.
NAME
The formal name of the field which is used in the form'scontents list.
ROWS
This gives the visible number of text lines shown by thefield. User agents should allow text to grow beyond these limits byscrolling as needed.
COLS
The visible number of characters across the field. Useragents should allow text to grow beyond these limits by scrolling asneeded.
DISABLED
When present, the field should be rendered as normal, butcan't be modified by the user. Where practical the rendering shouldprovide a cue that the field is disabled e.g. by graying out the text,changing the color of the background or similar.
ERROR
This attribute specifies an error message explainingwhy the field's current value is incorrect. When this attribute ismissing, the field can be assumed to be ok. User agents are recommendedto provide a cue to indicate that the field is in error.
ALIGN
Take values TOP or MIDDLE or BOTTOM, defining whether thetop or middle or bottom row of the field should be aligned with thebaseline for the text line in which the TEXTAREA element appears. Thedefault is align=top.

With ALIGN=LEFT, the field will float down and over to the currentleft margin, and subsequent text will wrap around the right hand sideof the field. Likewise for ALIGN=RIGHT, the field aligns with thecurrent right margin and, and text wraps around the left.

Fill-Out Forms (2024)
Top Articles
Latest Posts
Article information

Author: Pres. Lawanda Wiegand

Last Updated:

Views: 5812

Rating: 4 / 5 (51 voted)

Reviews: 82% of readers found this page helpful

Author information

Name: Pres. Lawanda Wiegand

Birthday: 1993-01-10

Address: Suite 391 6963 Ullrich Shore, Bellefort, WI 01350-7893

Phone: +6806610432415

Job: Dynamic Manufacturing Assistant

Hobby: amateur radio, Taekwondo, Wood carving, Parkour, Skateboarding, Running, Rafting

Introduction: My name is Pres. Lawanda Wiegand, I am a inquisitive, helpful, glamorous, cheerful, open, clever, innocent person who loves writing and wants to share my knowledge and understanding with you.