Font tag to manage color of the textRead the basic of html font tag here.
We can manage the color of the text in html by using font tag. Inside the font tag we have to specify color in HEX value. There is a color chart available here to give you the hex value of any color. Use that hex value to create different color font for your body tag. As font tag has one closing tag also so we can use font tag to mark part of a full text in different colors using font tag with different hex values of color.
Note that we can specify some colors directly inside the font tag. We will see some examples also. Here is a list of text with different color tags
Here is a line of text with different color within the same line.
Deprecated: FONT tag and its attributes are not supported in HTML5 ,
better to use styling using CSS.
Using CSS for font colorThere are three ways to define colour of font inside any html element.
1. KEYWORDS like red, blue, green , black
2. Hex value like #FFFFCC, #0000FF, #34CC00
3. RGB value like RGB(255,45,55)
KEYWORDS ( Black, Green, Yellow, Red )
HEX value of Red Green Blue ( #FFCC00, #00FFCC,#0000CC )
RGB ( Red Green Blue)The first number in RGB value mean value of Red from 0 to 255
Second number is the value of GREEN from 0 to 255
Third number is the value of Blue from 0 to 255
This article is written by plus2net.com team.