Firstly we have to type the Html code in any text editor or open the existing Html file in the text editor in which we want to use the style attribute for changing the color of a text.
What property is used to change the text colour of an element. HTML Web Development Front End Technology Use the color attribute in HTML to display the color of the text. What property is used to change the size of an HTML element. The CSS color property is used to change the text color of an element.
The color values can be expressed in RGB color numbers color keywords or in hexadecimal color numbers. Inherits this property from its parent element. Text-color can be set by using the name red hex value ff0000 or by its RGB valuergb 255 0 0.
Note This attribute is not supported in HTML5. So if you would want to modify your title innerHTML would be the way to go. Following is the syntax of using the color.
This CSS property sets the foreground color of the content of an element. With innerHTML you getset the content of an element. The CSS property used to control the elements------is -.
In your case however you just want to modify a property of the element change the color of the text inside it so you address the style property of the element itself. The CSS-------property defines the text color to be used. It will be a good idea to set the background color along.
Text-color property is used to set the color of the text. Which property is used to change the font of an element. These properties set the overall look and feel of your site as you place text on the foreground.