HTML and CSS Reference
In-Depth Information
figure 6-11
input box data types
Type
Displays
General Appearance
button
A button that can be clicked to perform an
action from a script
checkbox
A check box that can be clicked by the user
file
A Browse button to locate and select a file
hidden
A hidden field, not viewable on the form
image
An inline image that can be clicked to
perform an action from a script
password
An input box that hides text entered by
the user
radio
An option button that can be clicked by
the user
reset
A button that resets the form when clicked
submit
A button that submits the form when clicked
text
An input box that displays text entered by
the user
Creating an Input Control
• To create an input box for text entry, add the element
<input type=” type ” name=” name ” id=” id ” />
to the Web form, where type specifies the type of input control, the name attribute
provides the name of the field associated with the control element, and the id attri-
bute identifies the control element itself.
The first controls you'll add to the survey form will be seven text input boxes in which
each customer can enter a name, street address, city, state, postal code, phone number,
and e-mail address. You'll associate these input boxes with data fields named custname ,
street , city , state , zip , phone , and email , respectively. Before each input box you'll
insert a text string that describes its contents.
Search WWH ::




Custom Search