How to Format the Text Area

The HTML "textarea" tag gives your website or blog readers the ability to enter comments or feedback and submit the information to your email or database. This tag uses an optional "class" property to define the style applied to the element, such as the font, background color, font color and the element's width and height. Implement the textarea class on any Web page using CSS in your class style sheet.

Instructions

    • 1

      Right-click the CSS file you want to edit and select "Open With." Click the HTML editor that you'll use to edit the CSS file.

    • 2

      Add a textarea class. The following code creates a textarea class called "mycomments" that sets the font color, background color and size classes:

      textarea.mycomments {

      color: #000000;

      background-color: #FFFFFF;

      width: 400px;

      height: 400px;

      }

    • 3

      Close the CSS file and open your HTML document that links to the styles. Scroll down to the textarea element. If you do not already have a textarea defined, the following code shows you how to link the new CSS class to a new textarea element:

      <textarea class="mycomments"> </textarea>

Related Searches:

References

Comments

Related Ads

Featured