+ 1
how can we add colors to text?
5 Antworten
+ 4
Through CSS:
body {
color: green;
}
'body' is just an example. It could be any text content element.
+ 1
HTML can able change the font colour and also the background colour.
To change the colour of the font use the below code:
<font color="#FF0000">
This changes the font colour to red. To change to other colours then use the corresponding colour code.
For changing the background colour use
<body bgcolor="FFFF00">
This changes the background colour to yellow.
+ 1
If you don't want to use CSS add an style attribute in the opening tag
Exp
<p style="color:orange;"></p>
0
@rushika I don't think font tag is supported in HTML 5 :/
- 1
In the body you should give the tags fontcolor="colorname"