HTML font color Attribute
Definition and Usage
The color attribute specifies the font color of the content within the font element.Compatibility Notes
The font element was deprecated in HTML 4.01 and is not supported in XHTML 1.0 Strict DTD.Use CSS instead.
CSS syntax: <p style="color:red">
Syntax
<font color="color_value"> |
Syntax Example
<font color="red"> |
Attribute Values
Value | Description |
---|---|
color_name | Specifies the color using a color name. Like "red" |
rgb_value | Specifies the color using a RGB value. Like "rgb(255,0,0)" |
hex_value | Specifies the color using a hex value. Like"#ff0000" |
Browser Support
The attribute is deprecated, but still supported in all major browsers.Example
Source | Output |
---|---|
<font color="red"> <p>God is Great</p> </font> | God is Great |
HTML font color Attribute
Reviewed by 1000sourcecodes
on
04:17
Rating: