7. Write a statement (as you would in CSS) to set the division ContactUs with a black font color and white background. You may use, description, hexadecimal, or RGB code
Program code for the following question:
<!DOCTYPE html>
<html>
<head>
<style>
.myDiv {
color : black;
background-color: white;
}
body
{
background-color: blue;
}
</style>
</head>
<body>
<div class="myDiv">
<h2>ContactUs</h2>
</div>
</body>
</html>
In the above code, I used
body
{
background-color: blue;
}
just to make you see the font color and background color of ContactUs, it is optional.
Compilation of the above code:
Get Answers For Free
Most questions answered within 1 hours.