Name
bgColor — NN 4 IE n/a DOM n/a
Synopsis
Read/Write
Background color of the element. While you may set the value with
either a hexadecimal triplet or plain-language color value, values
returned from the property are for some reason the decimal equivalent
of the hexadecimal RGB version. The default behavior is a transparent
background created with a bgColor
property value
of null
.
Example
document.myIlayer.bgColor = "yellow"
Value
A hexadecimal triplet or plain-language color name. See Appendix A for acceptable plain-language color names.
Returned values are the decimal equivalent of the hexadecimal value.
A value of null
sets the background to
transparent.
Default
null
(transparent).
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.