HTML Forms: Passwords
INPUT elements of type PASSWORD are just like
text entry fields, except all characters are displayed
with an asterisk *.
<FORM METHOD="POST" ACTION="/cgi-bin/web-exe">
Enter your 8-character password:
<INPUT TYPE="password"
NAME="your_password"
SIZE="8"
MAXLENGTH="8">
</FORM>
-
NAME
-
VALUE
- Using the
VALUE tag, you can specify text which you
want as default, such as a group password.
-
SIZE
- Set the display size of the password entry field.
-
MAXLENGTH
- To limit the number of characters the user can input.
The form will give an error beep if the
user tries to type in more than the allowed
MAXLENGTH.
- If you are going to use
MAXLENGTH to limit the number
of characters entered, be sure to specify the same SIZE as
well, to show the user how much space they have.
- Even though your default
VALUE may be covered with
asterisks,
the user could see the actual text by viewing the HTML source of
the document.
|