background-attachment
Definition
The background-attachment property specifies if background images should scroll or be fixed in the browser window. The following screen shot shows a Web browser with a background image of a giraffe in the bottom right corner. The background-attachment property is set to fixed so that during scrolling in the browser, the image does not move.

The following screen shot shows a Web browser with a background image of a giraffe in the bottom right corner. The background-attachment property is set to scroll so that during scrolling in the browser, the image will be clipped by the viewable area.

Example
body {background: white url('images/giraffe.gif');background-repeat: no-repeat;background-position: right bottom;background-attachment: fixed;}
Characteristics
Possible values
scroll- Background images don't move with the scrolling mechanism of the Web browser.
fixed- Background images don't move with the element.
inherit- Use the same computed value as the parent element for this property.
Default value
scroll
Applies to
Inherited
No
See also