Prev | Current Page 222 | Next

Charles Wyke-Smith

"Stylin' with CSS: A Designer's Guide 2nd Edition"

This input has the type text, which makes it
appear as a single-line text ?¬? eld.
The control??™s id attribute associates it with the correct label
tag; note how the label??™s for attribute and the control??™s id attribute
match. The name attribute is used as the name part of the
name/value pair passed to the server when the form is submitted;
in this case, if the user enters the user name css whiz, then the
name/value pair passed to the server from this control would be
user_name=css whiz.
DESIGNING INTERFACE COMPONENTS 195
The size attribute determines how much text is visible in the
control and therefore its width??”in this case, 18 characters. The
maxlength determines how many characters can be entered into the
control, in this case, 36 characters.
THE PASSWORD INPUT CONTROL

An input with the type password is also a single-line ?¬? eld, as shown
in Figure 6.15, and all the above applies to its markup too, but the
user-typed text appears on-screen as a row of dots to prevent someone
reading your password as you type it in. Note, however, the text
typed is sent to the server as ???clear text???; that is, it is not encrypted
and is sent over the Internet to the server just like any other text
from the form. If text is transmitted over a secure connection (look
for https at the start of the page??™s URL), then it is encrypted as it
sent between the browser and the server.


Pages:
210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234