button
Google Custom Search

Using the in-line style attribute

In-line style is used in xhtml to format text, color, size, weight (boldness) and other properties. Study the examples below and practice with them in your web page.

Color of the font: To change the color of the text in a paragraph. <p style="color:blue;"> or <p style="color:#0000FF;">

The color of the text will be changed to blue and the paragraph will look like this.

To set the size of the text: To set the size of the text in a paragraph. <P style="font-size: 13pt;">

The paragraph will look like this.

Changing the weight of the font: To set the weight or the boldness of the font.. <p style="font-weight:bold;">

The paragraph will look like this.

The style of the font: The style of the font in a paragraph. <p style="font-style:italic;">

The paragraph will look like this.

Text-decoration: To decorate the text in a paragraph. <p style="text-decoration:underline;">

The paragraph will look like this.

The font-variant: The variant of the text. <p style="font-variant:small-caps;">

the paragraph will look like this.

This is an example of useing the in-line style attribute with several property variables..
<p style="color:blue; font-variant:small-caps; font-weight:bold; font-style:italic; ">

The paragraph will look like this: With the in-line style you can use multiple properties.

Practice with these examples on your web page.

go to the next terrific page To learn about using meta tags

Welcome to Pro-dezign Web Essentials, your IP address is: 38.103.63.60 and you came from: Page was directly requested

 

xhtml 1.0 strict