Text boxes: Used
to provide input fields for text, phone numbers, dates, etc.
<INPUT TYPE= "
TEXT "
>
Browser
will display
Textboxes
use the following attributes:
§TYPE:
text.
§SIZE:
determines the size of the textbox in characters. Default=20
characters.
§MAXLENGHT :
determines the maximum number of characters that the field will accept.
§NAME: is
the name of the variable to be sent to the CGI application.
§VALUE: will
display its contents as the default value.
Example on Text Box
<HTML>
<Head>
<TITLE>Form_Text_Type</TITLE>
</HEAD>
<BODY>
<h1> <font color=blue> Please enter the following BioData</font></h1>
<FORM name="form1" Method= " get " Action= " URL
" >
First Name: <INPUT
TYPE="TEXT" NAME="FName"
SIZE="15"
MAXLENGTH="25"><BR>
Last Name: <INPUT
TYPE="TEXT" NAME="LName"
SIZE="15"
MAXLENGTH="25"><BR>
Nationality: <INPUT
TYPE="TEXT" NAME="Country"
SIZE="25"
MAXLENGTH="25"><BR>
The Phone Number: <INPUT
TYPE="TEXT" NAME="Phone"
SIZE="15"
MAXLENGTH="12"><BR>
</FORM> </BODY> </HTML>
Output
Comments
Post a Comment