What is the correct HTML for adding a background color?

  • Thread starter Thread starter Jacob Black Rules
  • Start date Start date
J

Jacob Black Rules

Guest
< body bgcolor="yellow" > what i think!

< body color="yellow" >

< background>yellow
 
For the most simple case, the background color can be set using:
<body bgcolor = "yellow">

If you are using a stylesheet (CSS), then you can use something like:
<div style="background-color:yellow;">
 
For the most simple case, the background color can be set using:
<body bgcolor = "yellow">

If you are using a stylesheet (CSS), then you can use something like:
<div style="background-color:yellow;">
 
Back
Top