all
alt
ch
dir
id
min
rel
top
url
URL
urn
Expand Minimize

BGCOLOR attribute

Sets the background color behind an object.

Document Object Model (DOM) Level 2 HTML Specification, Section 1.6.5

Syntax

HTML
<element BGCOLOR="" ... >
JavaScript

Property values

sColor

A String that specifies one of the color names or RGB values in the Color Table.

Standards information

Remarks

Microsoft JScript supports the entire set of colors as color names and as the corresponding RGB values. However, JScript always returns the property as a string specifying the RGB color value, regardless of the format the value was set to.

Some browsers do not recognize color names; but all browsers should recognize RGB color values and display them correctly.

Requirements

Minimum supported client

Windows XP

Minimum supported server

Windows Server 2003

See also

col
colGroup
Reference
background
bgColor

 

 

Show:
© 2014 Microsoft