Name
BGCOLOR — NN all IE all HTML 3.2
Synopsis
BGCOLOR=”colorTripletOrName"
Optional
Establishes a fill color (behind the text and other content) for the
entire document. If you combine a BGCOLOR
and
BACKGROUND
, any transparent areas of the
background image let the background color show through. This
attribute is deprecated in HTML 4.0 in favor of the
background-color
style attribute.
Example
<BODY BGCOLOR="tan">...</BODY>
Value
A hexadecimal triplet or plain-language color name. A setting of
empty is interpreted as "#000000"
(black). See
Appendix A for acceptable plain-language color names.
Default
Varies with browser, browser version, and operating system.
Object Model Reference
- NN
[window.]document.bgColor
- IE
[window.]document.bgColor
[window.]document.body.bgColor
Get Dynamic HTML: The Definitive Reference now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.