HTML and CSS Reference
In-Depth Information
3. Save your changes to the file and then return to the forms.css file in your text
4. At the bottom of the style sheet file, insert the following style rule as shown in
Figure 6-43:
/* Text area styles */
textarea {
display: block;
font-size: 0.9em;
float: left;
height: 150px;
margin: 10px 0px;
width: 50%;
figure 6-43
style rule for the text area box
displays the text
area box a s a block
sets the font size to 0.9 em
floats the text area box on the left
makes the text area box 150 pixels high with a width of 50%
of the field set; sets the top and bottom margins to 10 pixels
5. Save your changes to the file and then reopen the survey.htm file in your Web
browser. Figure 6-44 shows the newly added text area box.
figure 6-44
text area box
6. Type some sample text into the text area box and verify that the text wraps to a
new line as you exceed the width of the box.
Trouble? Line wraps do not occur in the middle of words. If you find your sample
text is not wrapping to a new line, make sure you are entering individual words
rather than a long character string.
Search WWH ::

Custom Search