Test of Style Elements


<style></style>

The default text of this document is displayed in a smaller size in the Arial font because of the presence of the <style> element at the beginning of the document.

<font></font> (deprecated)

Alternatively, the font can be changed using the deprecated <font> element. In this case, a larger maroon Times New Roman font is displayed.

<div></div>

The <div> element can be used to apply a style over several block-level elements, such as the <p> element here.

Both paragraphs in this example have been rendered in italics by using the <div> "style" attribute.

The <div> element's "align" attribute can be used to right-justify text, for example, but this attribute is deprecated in favor of the "style" attribute.

<span></span>

The <span> element can be used to apply a style to a portion of the text, such as this section with a larger font in the middle of the sentence.