tag doesn’t have an effect, but like everything else in HTML, you can do amazing style things with it in CSS. Even though labels don’t typically have a default style, they are still useful. Building a password field
Passwords are just like text boxes, except the text isn’t displayed. Instead, a series of asterisks appears. Figure 7-4 shows a basic password field.
Figure 7-4: Enter the secret password.
The following code reveals that passwords are almost identical to ordinary text fields:
“http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd”>
password.html
In this example, I’ve created a password field with the ID pwd. The default value of this field is secret. The term secret won’t actually appear in the field; it will be replaced with six asterisk characters.
The password field offers virtually no meaningful security. It protects the user from the KGB glancing over his shoulder to read a password, but that’s about it. The open standards of XHTML and the programming languages mean passwords are often passed in the open. There are solutions — such as the SSL (Secure Socket Layer) technology — but for now, just be aware that the password field just isn’t suitable for protecting the recipe of your secret sauce.
This example doesn’t really do anything with the password, but you’ll use other technologies for that.
Making multi-line text input
The single-line text field is a powerful feature, but sometimes, you want something with a bit more space. The essay.html program, as shown in Figure 7-5, demonstrates how you might create a page for an essay question.
Figure 7-5: This quiz might require a multi-line response.
The star of this program is a new tag —