class

Support

The class attribute lets you assign to it one or more subtypes. These subtypes may then be used in CSS code for styling purposes, or by JavaScript code to make changes. The attribute takes as it's value a space-delimited list of one or more class names.

Example

<head>
    <style type="text/css">
        .roundify {
            -webkit-border-radius: 10px;
            width: 300px;
        }
        .blue {
            background-color: #0000FF;
            color: #FFF;
        }
    </style>
</head>
<body>
    <div class="roundify blue">
        <p>This div will appear blue with round borders.</p>
    </div>
</body>

Preview

This div will appear blue with round borders.