In our HTML tutorial we use the style attribute to introduce you to HTML styles.
HTML Style Examples
style="background-color:yellow"
style="font-size:10px"
style="font-family:Times"
style="text-align:center"
Deprecated Tags and Attributes
In HTML 4, some tags and attributes are defined as deprecated. Deprecated means that they will not be supported in future versions of HTML and XHTML.
The message is clear: Avoid the use of deprecated tags and attributes.
These tags and attributes should be avoided:
Tags
Description
Defines centered content
and
Defines HTML fonts
and
Defines strikeout text
Defines underlined text
Attributes
align
Defines the alignment of text
bgcolor
Defines the background color
color
Defines the text color
For all the above: Use styles instead.
Style Examples:
Background Color
The style attribute defines a style for the element.
The new style attribute makes the "old" bgcolor attribute obsolete.
Font Family, Color and Size
The style attribute defines a style for the
The new style attribute makes the old tag obsolete. Text Alignment
0 comments:
Post a Comment