all background colors internal css code example

Example 1: background color using css

/* To apply color to background you have to use 'background-color' property and value of property is color name. */
html,body {
  background-color: blue;
}

Example 2: fill color behid text in html

Put the text in an inline element, such as a <span>.

<h1><span>The Last Will and Testament of Eric Jones</span></h1>
And then apply the background color on the inline element.

h1 {
    text-align: center; 
}
h1 span { 
    background-color: green; 
}
An inline element is as big as its contents is, so that should do it for you.

Tags:

Misc Example