PERSONAL DATA FORM FOR CONDUCTING A SURVEY
|
Now You learn how to make a form as seen above:-
IMPUT TYPE="TEXT"
Imput dialog items:-
| the dialog item |
explaination for the dialog item |
| NAME="text" |
Identifying what the user was responding to when they filled in the text box |
| SIZE=value |
Specify the width of the text box in characters |
| MAXLENGTH=value |
Specify the maximum number of characters that can be written in the text box. If this is greater than can be displayed (as defined by the SIZE attribute, then the field will scroll |
| VALUE="text" |
Specify some default text for the text box(if it is blank then the text box will be blank) |
TYPE="textarea"
| form type |
form output |
html code for this form output |
| text area with three rows |
|
<TEXTAREA COLS=40 ROWS=3 WRAP="hard" NAME="personal text area">
</TEXTAREA>
|
| textarea with four rows |
|
<TEXTAREA COLS=30 ROWS=4 WRAP="hard" NAME="personal text area">
</TEXTAREA>
|
| textarea with default text |
|
<TEXTAREA COLS=30 ROWS=4 WRAP="hard" NAME="personal text area">
default text
</TEXTAREA>
|
The <TEXTAREA></TEXTAREA> element is used to provide a editable text input area for the user. Any default text you wish to give the text area should be placed between the two tags. You must include the end tag even if you don't want to provide any default text. You can specify the width and height of the text area and, for some browsers, the type of wrapping to apply to the input text.
| the dialog item |
explaination for the dialog item |
| NAME="text" |
This assigns a label to the text input by the user, thus identifying what the user was responding to |
| COLS=characters |
Specify the width of the text entry area in characters |
| ROWS=number |
Specify the height of the text entry area in rows |
| WRAP="off|soft|hard|l" |
Specifies how the text input should wrap. Setting WRAP="off" means no wrapping will occur - text is sent exactly as typed. Setting WRAP="soft" means the display wraps but the text is sent as typed. Setting WRAP="hard" means the display wraps and text is sent with line breaks at all wrap points. The default for Netscape browsers is off, for Internet Explorer it is soft |
TYPE="radio button"
All buttons within the same group must have the same NAME. A single radio button can be shown, provided it has a unique NAME
| the dialog item |
explaination for the dialog item |
| NAME="text" |
Tells the browser which radio button group the radio button belongs to. Also serves to assign a label to the radio button group, thus identifying what the user was responding to when they selected a radio button. |
| VALUE="text" |
The text that accompanies the radio button if it is selected by the user. This text can be used by a program (cgi-script, JavaScript, etc.) written to process the form; see "Making a form work". |
| CHECKED |
Specifies the default radio button |
TYPE="checkbox"
All buttons within the same group must have the same NAME. A single checkbox can be shown, provided it has a unique NAME
| the dialog item |
explaination for the dialog item |
| NAME="text" |
Tells the browser which checkbox group the checkbox belongs to. Also serves to assign a label to the checkbox group, thus identifying what the user was responding to when they selected a checkbox. |
| VALUE="text" |
The text that accompanies the checkbox if it is selected by the user. This text can be used by a program (cgi-script, JavaScript, etc.) written to process the form; see "Making a form work". |
| CHECKED |
Specifies the default checkbox |
TYPE="password"
A password text box is exactly the same as an ordinary text box except the text the user types does not show up on-screen; instead each character is usually rendered as an asterisk (*).
| the dialog item |
explaination for the dialog item |
| NAME="text" |
This assigns a label to the password submitted by the user, thus identifying what the user was responding to when they filled in the password box |
| SIZE=value |
Specify the width of the password box in characters |
| VALUE="text" |
Specify some default text for the password box |
TYPE="submit" TYPE="reset"
|