<FORM ACTION=action base> form tags </FORM> <FORM METHOD=method> form tags </FORM> <FORM ENCTYPE=media type> form tags </FORM> The form tag introduces a form, which is made up of INPUT elements, described in the sections that follow. A form may be inside structural HTML tags and may also contain structural tags. Using tables and other elements a form can take on various shapes and looks. The ACTION attribute defaults to the document's base address. The METHOD attribute can be GET or POST. GET specifies a query form, used to get data from a server. POST specifies a form that gives information to the server and perhaps causes a database to be updated or a message to be sent. The SCRIPT attribute points to a script to be run. The browser must be able to run the type of script that is specified. The default media type is 'application/x-www-form-urlencoded', which specifies how the browser puts the user responses on the form together to form a response URL that is then submitted to the server. If Target is specified then the output document will be loaded into the window specified by "target window name". The following are the predefined target names: _blank Will cause the link to be loaded into a new blank window. _self Will cause the link to be loaded into the same window the link was in. _parent Will cause the link to be loaded into the parent of this document. _top Will cause the link to be loaded into the full body of this window. Form Input Check Box <INPUT TYPE=CHECKBOX NAME=name VALUE=value> <INPUT TYPE=CHECKBOX NAME=name VALUE=value CHECKED> The checkbox type input tag specifies a boolean choice within the form that contains it. If more than one checkbox appears in the form with the same name the user can select none, one or several of the choices. The NAME attribute is a required field and is used to identify the data for the field. The VALUE attribute specifies the value that is returned if the box is checked. If the CHECKED attribute is specified, the box is initially selected. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. Form Input File <INPUT TYPE=FILE NAME=name ACCEPT=mime type list> The file type input tag allows the user to attach one or more files to the form for submission. The NAME attribute is a required field and is used to identify the data for the field. The ACCEPT attribute is a list of mime types that will be accepted. (e.g. "image/*" or "image/gif, image/jpeg"). The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. Form Input Hidden <INPUT TYPE=HIDDEN NAME=name VALUE=value> The hidden type input tag specifies a hard coded name-value pair within the form. This field is not displayed to the user. Both NAME and VALUE are required attributes. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. Form Input Image <INPUT TYPE=IMAGE NAME=name SRC="URL"> The image type input tag specifies an image to be presented to the user. As soon as the user clicks on the image, the form is submitted with the selected x y coordinates of the spot on the image and the data for the other form fields. The NAME attribute is a required field and is used to identify the data for the field. The SRC and ALIGN attributes are the same as in the Inline Image tag. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. Form Input Password <INPUT TYPE=PASSWORD NAME=name> <INPUT TYPE=PASSWORD NAME=name MAXLENGTH=length> <INPUT TYPE=PASSWORD NAME=name SIZE=size> <INPUT TYPE=PASSWORD NAME=name VALUE=value> The password type input tag specifies a single line text entry field within the form that contains it. The value entered by the user will be obscured as it is entered. The NAME attribute is a required field and is used to identify the data for the field. The MAXLENGTH attribute specifies the number of characters that can be entered into this field. If MAXLENGTH is not specified then there is no limit on the number of characters entered. If MAXLENGTH is longer than SIZE then the text field will scroll appropriately. The SIZE attribute specifies the amount of display space this field should take up. The default for SIZE will vary by browser. The VALUE attribute specifies the initial value of the field. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. Form Input Radio Button <INPUT TYPE=RADIO NAME=name VALUE=value> <INPUT TYPE=RADIO NAME=name VALUE=value CHECKED> The radio button type input tag allows a choice among a number of options. Normally more than one radio button will appear in the form with the same name. The user can then select only one of the of the choices. The NAME attribute is a required field and is used to identify the data for the field. If one of the choices has the CHECKED attribute it will initially be selected. If none of the choices has the CHECKED attribute then the first one defaults as initially selected. The VALUE attribute specifies the value that is returned if the box is checked. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. Form Input Range <INPUT TYPE=RANGE NAME=name MIN=min MAX=max> <INPUT TYPE=RANGE NAME=name MIN=min> MAX=max VALUE=value> The range type input tag allows the user to enter an number restricted to a set range. The NAME attribute is a required field and is used to identify the data for the field. The MIN and MAX attributes specify the minimum and maximum values that can be entered. If either MIN or MAX is a real number then the user can enter real numbers, otherwise only integers can be entered. The VALUE attribute specifies an initial value and should be in the range specified. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. Form Input Scribble <INPUT TYPE=SCRIBBLE NAME=name SRC=URL VALUE=text> The scribble type input tag allows the user draw on a predefined image. The NAME attribute is a required field and is used to identify the data for the field. The SRC attribute specifies the URL of the image. The VALUE attribute specifies a text string that is used as an alternate if images or scribbling are not supported by the browser. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. Form Input Submit <INPUT TYPE=SUBMIT> <INPUT TYPE=SUBMIT NAME=name> <INPUT TYPE=SUBMIT VALUE=value> The submit type input tag specifies a button. When the user clicks the button, the form is submitted. The NAME attribute is used to identify the data for the field. If no NAME attribute is given then this element does not form part of the submitted response. The VALUE attribute specifies the label for the button. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. Form Input Text <INPUT TYPE=TEXT NAME=name> <INPUT TYPE=TEXT NAME=name MAXLENGTH=length> <INPUT TYPE=TEXT NAME=name SIZE=size> <INPUT TYPE=TEXT NAME=name VALUE=value> The text type input tag specifies a single line text entry field within the form that contains it. The NAME attribute is a required field and is used to identify the data for the field. The MAXLENGTH attribute specifies the number of characters that can be entered into this field. If MAXLENGTH is not specified then there is no limit on the number of characters entered. If MAXLENGTH is longer than SIZE then the text field will scroll appropriately. The SIZE attribute specifies the amount of display space this field should take up. The default for SIZE will vary by browser. The VALUE attribute specifies the initial value of the field. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. Form Text Area <TEXTAREA NAME=name COLS=# columns ROWS=# rows> content </TEXTAREA> <TEXTAREA NAME=name COLS=# columns ROWS=# rows WRAP=type> content </TEXTAREA> The text area tag specifies a multiple line text area field within the form that contains it. The NAME attribute is a required field and is used to identify the data for the field. The COLS attribute specifies the width in characters of the text area. The ROWS attribute specifies the number of lines the text area contains. The content is used as an initial value for the field. The field can be scrolled beyond the COLS and ROWS size to allow for larger amounts of text to be entered. The WRAP attribute can have values of OFF, SOFT and HARD. The DISABLED attribute shows the field but will not allow the user to modify it. The ERROR attribute is used to supply an error message for the field. The ALIGN attribute is used to position the field and can be one of TOP, BOTTOM, MIDDLE, LEFT or RIGHT. | Tag List <!-- &tag; A ADDRESS APPLET AREA B BASE BASEFONT BGSOUND BIG BLINK BLOCKQUOTE BODY BR CAPTION CENTER CITE CODE COL COLGROUP DD DFN DIR DL DT EM EMBED FONT FORM FRAME FRAMESET Hn HEAD HR HTML I IFRAME IMG INPUT TYPE=CHECKBOX INPUT TYPE=FILE INPUT TYPE=HIDDEN INPUT TYPE=IMAGE INPUT TYPE=PASSWORD INPUT TYPE=RADIO INPUT TYPE=RANGE INPUT TYPE=RESET INPUT TYPE=SCRIBBLE INPUT TYPE=SELECT INPUT TYPE=SUBMIT INPUT TYPE=TEXT ISINDEX KBD LI LINK LISTING MAP MARQUEE MENU META MULTICOL NOBR NOFRAMES OBJECT OL P PARAM PLAINTEXT PRE SAMP SCRIPT SMALL SPACER STRIKE STRONG SUB SUP TABLE TBODY TD TEXTAREA TFOOT TH THEAD TITLE TR TT U UL VAR WBR XMP |